Simple Pywebview
application using React
for the frontend and Flask
to handle the backend.
Supported Platforms
Platforms | Tested |
---|---|
Windows | ✅ |
Linux [Debian based] |
✅ |
Clone this repo and run this commands on your terminal
yarn run init
that will install all dependencies to run the app.
Note : Please refer to installation guide and make sure all dependencies are set to run pywebview
application.
On your terminal run this command
yarn start
Note : This template only support hot reload to apply changes in your frontend
code you need but any changes on app/backend
code you need to close and run the app again.
Build the application using this command
yarn build
This will build the application to production on publish
directory.
Note : Please make sure to set
DEBUG = FALSE
in main.py
before deploying the app for production.
Serve React
Run this command to build serve react application.
yarn react-serve
Build React
Run this command to build react (frontend) application only.
yarn react-build
This will build the react application to production on dist
directory.
Code linting, use eslint
to lint your react code and flake8
to lint your python code.
react-lint
Run this command to lint your react code.
yarn react-lint
python-lint
Run this command to lint your python code.
yarn python-lint
Run this command install additional python dependencies.
yarn install-dep <dependency_1> <dependency_2>
That command will call pip
inside pywebview venv
to install python .