stewartpark / Flask-JSGlue

Flask-JSGlue helps hook up your Flask application nicely with the front end.
80 stars 40 forks source link

Better handling of invalid rule arguments #21

Closed jesseops closed 7 years ago

jesseops commented 7 years ago

This gives earlier feedback about invalid parameters to url_for. Very helpful when swapping back and forth between backend/frontend dev and forgetting the proper argument type.

stewartpark commented 7 years ago

This is awesome, but looks like the PR now has conflicts since we moved the js file into a separate template file. :'( Could've been coordinated better, sorry about that! Would you mind reapplying the change to the new file? 😁

italomaia commented 7 years ago

Hello @jesseops just checking on you. Would you mind updating your PR? Sorry for not seeing your PR before merging and causing the conflict.

jesseops commented 7 years ago

@italomaia Thanks for the reminder; haven't had a chance to update this yet. Will take a look this week.

rlam3 commented 7 years ago

Will this merge have any breaking changes to the previous version code base?

jesseops commented 7 years ago

I've updated the PR, moving my change into the template file. Should be good to go.

italomaia commented 7 years ago

@rlam3 well, by the looks, incorrect calls to url_for will break in the browser. Sounds scary, but it should avoid some weird bugs in the long run for most projects.

jesseops commented 7 years ago

@italomaia I've changed the import behavior to multi line.

italomaia commented 7 years ago

I summon @stewartpark

stewartpark commented 7 years ago

Looks good! Thanks @italomaia for reviewing, and @jesseops for the contribution! Merging.