8000 Update docs for basic build · jletey/unifiedjs.github.io@63d84c5 · GitHub
[go: up one dir, main page]

Skip to content

Commit 63d84c5

Browse files
committed
Update docs for basic build
1 parent 6705866 commit 63d84c5

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

readme.md

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,32 +6,35 @@
66

77
## Build
88

9-
This is a slow site to build!
9+
Do `npm i` and then `npm t`, which checks and builds the site.
10+
This basic build uses two shortcuts over the full build:
11+
12+
* Images are not optimised
13+
* Data is not crawled
14+
15+
The full build is a slow site to properly build!
1016
Takes about 20 minutes (🤯) on my tiny trusted 12 inch MacBook.
1117
The reason for this is that it crawls the whole ecosystem.
1218
We contact 5 API’s: GitHub, npm, npms, OpenCollective, and BundlePhobia.
1319
When generating, it builds a performant static site.
1420
Everything is minified.
1521
Images are highly optimised.
1622

17-
To build the site, create a `.env` file with the following tokens:
23+
To fully build the site, create a `.env` file with the following tokens:
1824

1925
```ini
2026
GH_TOKEN=123123123
2127
NPM_TOKEN=456456456
2228
OC_TOKEN=789789789
2329
```
2430

25-
Then, `npm install` and `npm test` should do the trick!
31+
Then, `npm install` and `UNIFIED_OPTIMIZE_IMAGES=1 npm test` should do the
32+
trick!
2633

2734
```sh
28-
npm i && npm t
35+
npm i && UNIFIED_OPTIMIZE_IMAGES=1 npm t
2936
```
3037

31-
If you are contributing, for example, by writing an article in the learning
32-
section, then make changes to `learn/` and instead use `npm run format` to
33-
check if everything’s OK.
34-
3538
[site]: https://unifiedjs.com
3639

3740
[screenshot]: screenshot.png

0 commit comments

Comments
 (0)
0