Commit
Β·
9d0b14d
1
Parent(s):
dde6bca
Updated Space metadata
Browse files
README.md
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
emoji: π
|
4 |
colorFrom: yellow
|
5 |
colorTo: purple
|
@@ -9,40 +9,7 @@ license: apache-2.0
|
|
9 |
header: mini
|
10 |
app_file: dist/index.html
|
11 |
thumbnail: https://huggingface.co/spaces/nanotron/distill-blog-template/resolve/main/thumbnail.png
|
12 |
-
short_description:
|
13 |
---
|
14 |
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
Instruction to install and run locally
|
19 |
-
|
20 |
-
```bash
|
21 |
-
npm install
|
22 |
-
npm run build
|
23 |
-
npm run dev
|
24 |
-
|
25 |
-
// If you want to change something change it in src/....
|
26 |
-
|
27 |
-
// Once you are finished
|
28 |
-
npm run build
|
29 |
-
// And commit the dist folder
|
30 |
-
```
|
31 |
-
|
32 |
-
## Loading HTML fragments:
|
33 |
-
There are two way to load HTML fragments:
|
34 |
-
1. Compile them into html during build time
|
35 |
-
2. Fetch them and insert them during run-time
|
36 |
-
|
37 |
-
## When to use what
|
38 |
-
- Use compile time fragments only on parts which you want to ensure are seen by every user right after page load (e.g logo)
|
39 |
-
- Use run-time fragments for everything else so that the final HTML is of reasonable size (<1MB idealy)
|
40 |
-
|
41 |
-
## How to add a new fragment
|
42 |
-
- Add it to the `src/fragments` folder (e.g. `src/fragments/banner.html`)
|
43 |
-
- For run-time fragments, add {{{fragment-name}}} to appropriate place in `src/index.html` (e.g. {{{fragment-banner}}})
|
44 |
-
- For compile-time fragments, add <div id="fragment-name"></div> to `src/index.html` where you want to insert the fragment (e.g. <div id="fragment-banner"></div>)
|
45 |
-
|
46 |
-
|
47 |
-
## How to know which fragments are available
|
48 |
-
- Run `npm run dev` and look at the console for available fragments
|
|
|
1 |
---
|
2 |
+
title: All about Enterprise Hub
|
3 |
emoji: π
|
4 |
colorFrom: yellow
|
5 |
colorTo: purple
|
|
|
9 |
header: mini
|
10 |
app_file: dist/index.html
|
11 |
thumbnail: https://huggingface.co/spaces/nanotron/distill-blog-template/resolve/main/thumbnail.png
|
12 |
+
short_description: Why you need it, how to get it
|
13 |
---
|
14 |
|
15 |
+
Built from the Distill Blog Template credits Leandro von Werra : https://huggingface.co/spaces/lvwerra/distill-blog-template-exp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|