Linux command
jupyterlite 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Build JupyterLite site
jupyter lite build
Build with specific content
jupyter lite build --contents [notebooks/]
Serve built site locally
jupyter lite serve
Build with additional packages
jupyter lite build --piplite-wheels [package.whl]
Clean build artifacts
jupyter lite clean
Check configuration
jupyter lite status
Build with custom output
jupyter lite build --output-dir [dist/]
Initialize configuration
jupyter lite init
说明
jupyter lite builds static JupyterLab sites that run entirely in the browser using WebAssembly. No server required—deploy to any static hosting. build generates HTML, JavaScript, and assets in the output directory. Include notebooks with --contents to pre-populate the file browser. The resulting site runs JupyterLab with Pyodide kernel. The Pyodide kernel executes Python in WebAssembly. Pre-install packages with --piplite-wheels or install at runtime via piplite. Many scientific Python packages are available. serve starts a local HTTP server for testing. The build output can deploy to GitHub Pages, Netlify, or any static host. No backend infrastructure needed. Configuration via jupyter_lite_config.json customizes settings, extensions, and build behavior. init creates template files.
参数
- --contents _path_
- Path to content directory for notebooks.
- --output-dir _path_
- Output directory for built site. Default: _output.
- --piplite-wheels _path_
- Include pip wheels for piplite.
- --pyodide _url_
- Custom Pyodide distribution URL.
- --port _port_
- Port for serve command. Default: 8000.
- --lite-dir _path_
- Source directory for JupyterLite files.
- --settings-overrides _file_
- JSON file with settings overrides.
- --no-sourcemaps
- Disable source maps in build.
FAQ
What is the jupyterlite command used for?
jupyter lite builds static JupyterLab sites that run entirely in the browser using WebAssembly. No server required—deploy to any static hosting. build generates HTML, JavaScript, and assets in the output directory. Include notebooks with --contents to pre-populate the file browser. The resulting site runs JupyterLab with Pyodide kernel. The Pyodide kernel executes Python in WebAssembly. Pre-install packages with --piplite-wheels or install at runtime via piplite. Many scientific Python packages are available. serve starts a local HTTP server for testing. The build output can deploy to GitHub Pages, Netlify, or any static host. No backend infrastructure needed. Configuration via jupyter_lite_config.json customizes settings, extensions, and build behavior. init creates template files.
How do I run a basic jupyterlite example?
Run `jupyter lite build` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does --contents _path_ do in jupyterlite?
Path to content directory for notebooks.