aboutsummaryrefslogtreecommitdiffstats
path: root/lib/buildcss/readme.txt
blob: fab5366829afe54cb5ef0a58a8946d61cf48cb2d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
For nav we don't need the complete CSS/JS and to avoid breaking webapps (bugs/blog/forums/etc) we add it in a class.
For the CSS, we include only require bootstrap class to the nav, and we add them within the ".mganav" class, see mga-bootstrap.scss
For the JS we only need the collapse, this help to minify it.

This is to help to generate these two files.

install npm: 
urpmi npm

Download source on https://github.com/twbs/bootstrap/archive/v4.6.0.zip 

cd bootstrap-4.6.0/
mkdir mga

install local dependencies: 
npm install

add mga-bootstrap.scss in scss/

Add on package.json:
    "mga": "npm-run-all css js mga-*",
    "mga-js": "terser js/dist/util.js js/dist/collapse.js --compress typeofs=false --mangle --output mga/bootstrap.min.js",
    "mga-css": "cleancss -O1 --format breakWith=lf --output mga/bootstrap.min.css dist/css/mga-bootstrap.css",

run everything:
npm run mga

the file are on mga/