File tree Expand file tree Collapse file tree 4 files changed +8
-6
lines changed Expand file tree Collapse file tree 4 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -35,8 +35,8 @@ yarn demo-node
3535Serve the project locally:
3636
3737``` sh
38- # Build the package for web
39- yarn pack-web
38+ # Build and bundle the demo for web
39+ yarn pack-demo- web
4040
4141# Host the `ledger-amino` package directory, for example using Python 3
4242python3 -m http.server
Original file line number Diff line number Diff line change 55 < meta name ="viewport " content ="width=device-width, initial-scale=1.0 " />
66 < title > Ledger Demo</ title >
77 < link rel ="stylesheet " href ="index.css "> </ style >
8- < script src ="../dist /demo/ledger.js "> </ script >
8+ < script src ="../build /demo-bundle /ledger.js "> </ script >
99 </ head >
1010 < body >
1111 < section >
Original file line number Diff line number Diff line change 1515 " *.md" ,
1616 " !*.spec.*" ,
1717 " !*testutils.*" ,
18+ " !**/demo/" ,
19+ " !**/demo-bundle/" ,
1820 " !**/karma-bundle/" ,
1921 " !**/testdata/"
2022 ],
3638 "test" : " yarn build-or-skip && yarn test-node" ,
3739 "demo-node" : " yarn build-or-skip && node ./demo/node.cjs" ,
3840 "coverage" : " nyc --reporter=text --reporter=lcov yarn test --quiet" ,
39- "pack-web" : " yarn build-or-skip && webpack --mode development --config webpack.demo.config.cjs"
41+ "pack-demo- web" : " yarn build-or-skip && webpack --mode development --config webpack.demo.config.cjs"
4042 },
4143 "dependencies" : {
4244 "@cosmjs/amino" : " workspace:^" ,
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ const path = require("path");
33const webpack = require ( "webpack" ) ;
44
55const target = "web" ;
6- const demodir = path . join ( __dirname , "dist " , "demo" ) ;
6+ const demoBundleDir = path . join ( __dirname , "build " , "demo-bundle " ) ;
77
88module . exports = [
99 {
@@ -12,7 +12,7 @@ module.exports = [
1212 entry : globSync ( "./build/demo/web.js" , { dotRelative : true } ) . sort ( ) ,
1313 output : {
1414 asyncChunks : false ,
15- path : demodir ,
15+ path : demoBundleDir ,
1616 filename : "ledger.js" ,
1717 } ,
1818 plugins : [
You can’t perform that action at this time.
0 commit comments