HSLdevcom / localroute

Javascript library for public transport route planning
GNU General Public License v3.0
32 stars 13 forks source link

Fix most compiler warnings. #1

Closed jjrv closed 10 years ago

jjrv commented 10 years ago

Add type annotations and missing declarations, remove dead code.

haphut commented 10 years ago

It is quite common to have the compiled result in dist, at least for tagged releases. As the build system is currently not committed into the repo, in my opinion the user should have some way to use the library.

jjrv commented 10 years ago

Better if I'll add the build system then, otherwise all commits would have identical changes to both versions of the source. For releases I agree it should be included.

haphut commented 10 years ago

I think it'd be slightly nasty to add the Closure python tools into this repo. Perhaps a quick fix like this script suffices for now.

In the long run, after writing more documentation, it might make sense to turn localroute.js into an npm package. One would start by writing a package.json (examples 1,2,3,4; doc). You could add some Google Closure compiler wrapper as a dependency. There are many, this is one of them.

Then you'd have to rewrite the build process, which is perhaps the most arduous part. Grunt and its many plugins are often used for that. It's got at least two plugins for Closure. Of course there are other compressors as well.

I think npm packaging should not be a high priority right now.