@architect/plugin-bundles
v3.2.0
Published
Architect plugin for exposing bundled modules to the browser from your Architect project.
Downloads
213
Readme
plugin-bundles
Plugin for exposing bundled modules to the browser from your Architect project.
Install
npm i @architect/plugin-bundles
Usage
In your app.arc
file:
@app
bndl-mock
@http
get /yolo
# Define you plugins pragma
@plugins
# Add the plugin bundles module
architect/plugin-bundles
# Define the bundles pragma
@bundles
# Specify which modules to bundle based off of file path.
# . Hint: You can include organization node modules by quoting the path
# . i.e. hashids "@begin/hashids"
yolo /lib/yolo.mjs
Bundles are will now be available at /_static/bundles/yolo.mjs
🙌 Turn fingerprinting on and use
static.json
to retrieve the fingerprinted file name.