Comments (8)
What did you run for a start command??
Did you get any errors?
from bootstrap-npm-starter.
I don't if anyone has had a chance to look into this or not, but if testing shows we need a solution I have a couple ideas:
-
npx
https://blog.npmjs.org/post/162869356040/introducing-npx-an-npm-package-runner -
Add 'start' to npm.scripts in package.json
There is also another (seperate) open ticket requesting we simplify the start command to resemble React's
'create-react-app' command- I would like to see if anyone thinks that npx and/or adjustments to package.json could rectify the situation. I will do run a bunch of tests later to see if I can reproduce these problems and see if I can troubleshoot it.
from bootstrap-npm-starter.
@codewithklutch Hi, I executed npm run watch
and npm run serve
, then I modified some css, the browser neither reload or live hot reload. I have enabled live reload extension of chrome. There is not any errors on the terminal.
from bootstrap-npm-starter.
The server npm module doesn't look like it handles live reloading so there isn't a way of live reloading. I think @mdo is looking at moving this to Webpack or something else which would have these capabilities.
from bootstrap-npm-starter.
For live reload, I think it would be worth exploring using live reload's cli instead of using nodemon, I haven't done this yet so if anyone has and has run into issues, please let me know.
As for adjustments other adjustments to package.json as @codewithklutch mentioned I'd be more than happy to submit a PR to add any of following:
- using the config object as "variables" in the npm scripts to configuration more powerful (see example below)
- using npm script lifecycles so that
npm run css
would run precss, css and postcss scripts. - adding babel to compile JavaScript
Example of config object and "variables" (not what they are actually called, but I'm using the term):
"config": {
"babel":"./node_modules/.bin/babel",
"presets":"@babel/preset-env",
"plugins":"@babel/plugin-proposal-optional-chaining,@babel/plugin-proposal-function-bind",
"sourcemaps": "false",
"style": "compact",
"src": "./src/",
"dest": "./public",
"page": "./src/index.html",
"port": "3000",
"extentions": "html,scss,js",
"ignore ": "",
},
"scripts": {
"js": "babel $npm_package_config_src/js --out-dir $npm_package_config_dest --presets=$npm_package_config_presets --plugins $npm_package_config_plugins",
"precss": "node-sass --include-path node_modules --output-style $npm_package_config_style --source-map true --source-map-contents true --precision 6 $npm_package_config_src/scss -o $npm_package_config_dest/css",
"css": "purgecss --css $npm_package_config_src/css/*.css --content $npm_package_config_page --output $npm_package_config_dest/css/",
"postcss": "postcss --replace $npm_package_config_dest/css/*.css --use autoprefixer --map",
"minify:css": "cssnano < $npm_package_config_dest/css/bootstrap.css > $npm_package_config_dest/css/bootstrap.min.css",
"server": "serve --listen $npm_package_config_port",
"watch": "nodemon -e $npm_package_config_extentions -x \"npm run css && npm run js\"",
},
from bootstrap-npm-starter.
Slick!!!!
from bootstrap-npm-starter.
How we can add live-reload functionality in this project? Any advice?
from bootstrap-npm-starter.
Closing as a won't fix—please see #95 and consider migrating to one of our newer examples with Bootstrap 5 at https://github.com/twbs/examples.
from bootstrap-npm-starter.
Related Issues (20)
- As
- Kerbabies
- npm ERR! missing script: css-compile HOT 1
- Recommend Node version in REAMDE
- branch: v5-parcel -- @parcel/transformer-sass: Can't find stylesheet to import @import "vendor/rfs"; HOT 1
- Build Steps and configuration for Cloudflare Pages integration HOT 1
- Please update to v5 with current npm version. Current show error on installing.
- config file and autoload HOT 1
- Ttke HOT 1
- compiling errors because node-sass is deprecated
- Purge CSS issues HOT 1
- > `#include` <unistd.h>
- Auto tab refresh
- V6 Test of Skilldatabase
- Issue with node version 16 HOT 4
- Tax calculator
- Add Gulp HOT 1
- Add ViteJS HOT 1
- Compiling error using node v16.18.1 HOT 3
- Update please HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bootstrap-npm-starter.