weas and weas-widget are separate repos, but if we want to debug/develop a new feature of weas for the widget, using bundling makes the development more convenient.
The js code was moved to the js folder, run npm run build-watch will bundle these assets into the src/weas_widget/static folder, and watch the changes.
Use local weas
If we want to use the weas package, then clone the weas repo, and the two repo folders are in the same level.
import * as weas from "../../weas/src/index.js";
import "./widget.css";
Use release weas version
If we want to use the release version from unpkg
import * as weas from "https://unpkg.com/weas/dist/weas.mjs";
import "./widget.css";
weas and weas-widget are separate repos, but if we want to debug/develop a new feature of weas for the widget, using bundling makes the development more convenient.
The js code was moved to the
js
folder, runnpm run build-watch
will bundle these assets into thesrc/weas_widget/static
folder, and watch the changes.Use local weas
If we want to use the weas package, then clone the weas repo, and the two repo folders are in the same level.
Use release weas version
If we want to use the release version from unpkg
Publish Python package
npm run build