{"id":16418491,"url":"https://github.com/nitely/python-react-v8","last_synced_at":"2025-03-16T17:33:54.487Z","repository":{"id":57457469,"uuid":"58569397","full_name":"nitely/python-react-v8","owner":"nitely","description":":star: Render React.js views server-side","archived":true,"fork":false,"pushed_at":"2019-10-22T23:39:39.000Z","size":66,"stargazers_count":79,"open_issues_count":3,"forks_count":6,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-03T01:07:27.968Z","etag":null,"topics":["python","react","server-rendered","v8","v8-cffi"],"latest_commit_sha":null,"homepage":"http://python-react-v8.readthedocs.io","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nitely.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-05-11T18:14:35.000Z","updated_at":"2025-02-11T13:44:25.000Z","dependencies_parsed_at":"2022-09-06T01:23:28.072Z","dependency_job_id":null,"html_url":"https://github.com/nitely/python-react-v8","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitely%2Fpython-react-v8","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitely%2Fpython-react-v8/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitely%2Fpython-react-v8/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitely%2Fpython-react-v8/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nitely","download_url":"https://codeload.github.com/nitely/python-react-v8/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243908443,"owners_count":20367412,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["python","react","server-rendered","v8","v8-cffi"],"created_at":"2024-10-11T07:14:16.749Z","updated_at":"2025-03-16T17:33:54.061Z","avatar_url":"https://github.com/nitely.png","language":"Python","readme":"# Python-React-V8\n\n[![Build Status](https://img.shields.io/travis/nitely/python-react-v8.svg?style=flat-square)](https://travis-ci.org/nitely/python-react-v8)\n[![Coverage Status](https://img.shields.io/coveralls/nitely/python-react-v8.svg?style=flat-square)](https://coveralls.io/r/nitely/python-react-v8)\n[![pypi](https://img.shields.io/pypi/v/python-react-v8.svg?style=flat-square)](https://pypi.python.org/pypi/python-react-v8)\n[![licence](https://img.shields.io/pypi/l/python-react-v8.svg?style=flat-square)](https://raw.githubusercontent.com/nitely/python-react-v8/master/LICENSE)\n\nThin wrapper around [v8-cffi](https://github.com/nitely/v8-cffi) to render React views server-side.\n\n\n## Compatibility\n\n[What v8-cffi supports](https://github.com/nitely/v8-cffi#compatibility)\n\n\n## Install\n\n```\n$ pip install python-react-v8\n```\n\n\n## Usage\n\n```python\nimport react\n\nfrom my_web_framework import render, orm, runserver\n\n\ndef index(request):\n    \"\"\"A naive implementation for a fake web-framework\"\"\"\n    data = orm.query().only('name', 'age', 'location')\n    react_ = react.React({\n        'url': request.get_full_url(),\n        'data': data})\n    context = {\n        'content': react_.render(),\n        'data': react_.to_json(data)}\n\n    return render('index.html', context)\n\n\nif __name__ == '__main__':\n    react.set_up() # Initialize V8 machinery\n    react.utils.load_libs(['./bundle.js'])\n    runserver(index)\n```\n\nRead the [docs](http://python-react-v8.readthedocs.org/en/latest/).\n\n\n## Examples\n\n* [Flux](https://github.com/nitely/python-react-v8/tree/master/examples/flux)\n* [Simple](https://github.com/nitely/python-react-v8/tree/master/examples/simple)\n\n\n## Build examples\n\n```\n$ make build-examples\n```\n\n\n## Tests\n\n```\n$ make test\n```\n\n\n## License\n\nMIT\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnitely%2Fpython-react-v8","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnitely%2Fpython-react-v8","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnitely%2Fpython-react-v8/lists"}