anuragsoni / routes

typed bidirectional router for OCaml/ReasonML web applications
https://anuragsoni.github.io/routes/
BSD 3-Clause "New" or "Revised" License
145 stars 11 forks source link

Update bsconfig.json name #109

Closed tsnobip closed 4 years ago

tsnobip commented 4 years ago

name should be the same in bsconfig.json and package.json (https://bucklescript.github.io/docs/en/build-configuration.html#name-namespace). Otherwise when you use this lib with Bucklescript, it generates

var Routes = require("routes/src/routes.js");

which is not found since in node_modules the routes folder is nested inside @anuragsoni like set up in package.json, it should be

var Routes = require("@anuragsoni/routes/src/routes.js");

which is what is generated with the correct bsconfig name.

anuragsoni commented 4 years ago

Thank you!

tsnobip commented 4 years ago

You're more than welcome, thanks to you! This lib is awesome, plus I really like the fact it's cross-platform and so easily pluggable!

anuragsoni commented 4 years ago

Does npm let you use dependencies from github? If it is possible to verify that this change looks good, i can prepare a new release to publish it on npm.

anuragsoni commented 4 years ago

You're more than welcome, thanks to you! This lib is awesome, plus I really like the fact it's cross-platform and so easily pluggable!

Thank you! I'm glad you find this library useful! Don't hesitate to open issues/provide feedback for anything else that will help with bucklescript or your other reason/ocaml projects.

tsnobip commented 4 years ago

yes I just checked it out from master, it works, thanks a lot :)

anuragsoni commented 4 years ago

Thanks for confirming. I will prepare a release soon.

tsnobip commented 4 years ago

Cool! I'm thinking about building a framework in Bucklescript on top of node or an existing framework and your routing solution is perfect for this!