Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mshenfield/todomvc.py
Helping intrepid Pythonistas experiment with Python in the browser
https://github.com/mshenfield/todomvc.py
Last synced: about 13 hours ago
JSON representation
Helping intrepid Pythonistas experiment with Python in the browser
- Host: GitHub
- URL: https://github.com/mshenfield/todomvc.py
- Owner: mshenfield
- License: other
- Created: 2018-04-22T12:37:34.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-04-30T01:22:49.000Z (over 6 years ago)
- Last Synced: 2024-06-11T20:35:02.420Z (5 months ago)
- Language: Python
- Size: 5.27 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# TodoMVC.py
Helping intrepid Pythonistas experiment in the browser.Based of of [TodoMVC](http://todomvc.com/), this provides examples of different Python -> JS solutions in the browser.
## Oh God, Why?
Python's clean syntax, and the ability to customize that syntax with operator operator overloading and metaclassess, make it a great tool for writing great tools and everyday applications. I'm tantalized by the possibility of sharing code between the frontend and the backend, especially data validation logic that's useful in both client-side forms and server-side views. There are also domains that Python is better at - being able to deploy a version of your server-side machine learning model to the browser would be awesome. Finally, being able to write web apps in the same language as server code could lower the barrier to entry for Python programmers to jump into the frontend. Despite many improvements, JavaScript [still](https://stackoverflow.com/questions/3127429/how-does-the-this-keyword-work#3127609) [has](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Loops_and_iteration#Arrays) [warts](https://github.com/getify/You-Dont-Know-JS/blob/master/this%20%26%20object%20prototypes/apA.md#class-gotchas) that discourage Pythonistas from learning it.
### A Word of Caution to this Tale
The [tools](http://immutable.js/) [and](http://webpack.js.org/) [frameworks](https://reactjs.org/) [available](http://vuejs.org/) to the JavaScript ecosystem are [absurdly](http://www.jsfuck.com/) [powerful](https://mozilla.github.io/pdf.js/) and [comprehensive](https://github.com/facebook/react-devtools) [JavaScript is quickly evolving](https://babeljs.io/) into a [pretty good](https://media.giphy.com/media/8kqrtQiz9YqnS/giphy.gif) language. Even if you make the leap into Python on the frontend, be prepared to use JavaScript tools and interfaces.## Frameworks
* [Brython](http://www.brython.info) + [Brython `browser`](http://www.brython.info/static_doc/en/browser.html)
## Roadmap
* Slides for presentation
* [Transcrypt + React](http://www.transcrypt.org/examples#react_demo)
* Example of sharing code on the client and server
* Updated version of [Python in the Browser](http://stromberg.dnsalias.org/~strombrg/pybrowser/python-browser.html) with a focus on active frameworks.
* Live site of examples
* (maybe?) PYX - JSX for Python.## Contributing
Contributions are welcome! Follow the spec and instructions in the original [TodoMVC](https://github.com/tastejs/todomvc/blob/master/app-spec.md) to create a new sub-site. Using `setup.py` or a [`Pipfile`](https://docs.pipenv.org/) is encouraged, and your app wil likely live in `python/app.py` instead of `js/app.js`.## License
[MIT](LICENSE.md) © Max Shenfield.