@docsector/docsector-reader 0.2.0 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@docsector/docsector-reader",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "A documentation rendering engine built with Vue 3, Quasar v2 and Vite. Transform Markdown into beautiful, navigable documentation sites.",
|
|
5
5
|
"productName": "Docsector Reader",
|
|
6
6
|
"author": "Rodrigo de Araujo Vieira",
|
|
@@ -10,50 +10,68 @@ Docsector Reader is a **documentation rendering engine** built with Vue 3, Quasa
|
|
|
10
10
|
|
|
11
11
|
## Installation
|
|
12
12
|
|
|
13
|
+
Scaffold a new documentation project with the CLI:
|
|
14
|
+
|
|
13
15
|
```bash
|
|
14
|
-
npx
|
|
16
|
+
npx @docsector/docsector-reader init my-docs
|
|
15
17
|
cd my-docs
|
|
16
18
|
npm install
|
|
17
19
|
```
|
|
18
20
|
|
|
21
|
+
This creates a ready-to-use project with all necessary configuration files, a sample page registry, and i18n setup.
|
|
22
|
+
|
|
19
23
|
## Development Server
|
|
20
24
|
|
|
21
25
|
Start the dev server with hot-reload:
|
|
22
26
|
|
|
23
27
|
```bash
|
|
24
|
-
npx
|
|
28
|
+
npx docsector dev
|
|
25
29
|
```
|
|
26
30
|
|
|
27
31
|
The documentation site will be available at **http://localhost:8181**.
|
|
28
32
|
|
|
33
|
+
You can also specify a custom port:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
npx docsector dev --port 3000
|
|
37
|
+
```
|
|
38
|
+
|
|
29
39
|
## Production Build
|
|
30
40
|
|
|
31
41
|
Build an optimized SPA for deployment:
|
|
32
42
|
|
|
33
43
|
```bash
|
|
34
|
-
npx
|
|
44
|
+
npx docsector build
|
|
35
45
|
```
|
|
36
46
|
|
|
37
47
|
The output is placed in `dist/spa/` — ready to deploy to any static hosting.
|
|
38
48
|
|
|
49
|
+
To preview the production build locally:
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
npx docsector serve
|
|
53
|
+
```
|
|
54
|
+
|
|
39
55
|
## Project Structure
|
|
40
56
|
|
|
41
|
-
|
|
57
|
+
After `init`, your project will have this structure:
|
|
42
58
|
|
|
43
|
-
- `docsector.config.js` — Branding, links, languages
|
|
59
|
+
- `docsector.config.js` — Branding, links, languages, GitHub config
|
|
60
|
+
- `quasar.config.js` — Thin wrapper using `createQuasarConfig()` from the package
|
|
61
|
+
- `index.html` — HTML entry point with title and meta tags
|
|
44
62
|
- `src/pages/index.js` — Page registry (routes and metadata)
|
|
45
63
|
- `src/pages/guide/` — Guide-type pages (Markdown files)
|
|
46
64
|
- `src/pages/manual/` — Manual-type pages (Markdown files)
|
|
47
|
-
- `src/
|
|
48
|
-
- `src/
|
|
49
|
-
- `
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
- `src/boot/` — Boot files (store, i18n, QZoom, axios)
|
|
65
|
+
- `src/i18n/index.js` — i18n loader using `buildMessages()` from the package
|
|
66
|
+
- `src/i18n/tags.hjson` — Search keywords per route and locale
|
|
67
|
+
- `public/` — Static assets (logo, favicon, images)
|
|
68
|
+
|
|
69
|
+
The rendering engine (components, layouts, router, store, composables) lives inside the `@docsector/docsector-reader` package — you only maintain your content and configuration.
|
|
53
70
|
|
|
54
71
|
## Next Steps
|
|
55
72
|
|
|
56
73
|
- Configure your project branding in **docsector.config.js**
|
|
57
74
|
- Define your pages in **src/pages/index.js**
|
|
58
75
|
- Write your documentation in **Markdown**
|
|
76
|
+
- Add search keywords in **src/i18n/tags.hjson**
|
|
59
77
|
- Customize themes and appearance
|
|
@@ -10,50 +10,68 @@ Docsector Reader é um **motor de renderização de documentação** construído
|
|
|
10
10
|
|
|
11
11
|
## Instalação
|
|
12
12
|
|
|
13
|
+
Crie um novo projeto de documentação com o CLI:
|
|
14
|
+
|
|
13
15
|
```bash
|
|
14
|
-
npx
|
|
16
|
+
npx @docsector/docsector-reader init my-docs
|
|
15
17
|
cd my-docs
|
|
16
18
|
npm install
|
|
17
19
|
```
|
|
18
20
|
|
|
21
|
+
Isso cria um projeto pronto para uso com todos os arquivos de configuração, um registro de páginas de exemplo e setup de i18n.
|
|
22
|
+
|
|
19
23
|
## Servidor de Desenvolvimento
|
|
20
24
|
|
|
21
25
|
Inicie o servidor dev com hot-reload:
|
|
22
26
|
|
|
23
27
|
```bash
|
|
24
|
-
npx
|
|
28
|
+
npx docsector dev
|
|
25
29
|
```
|
|
26
30
|
|
|
27
31
|
O site de documentação estará disponível em **http://localhost:8181**.
|
|
28
32
|
|
|
33
|
+
Você também pode especificar uma porta personalizada:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
npx docsector dev --port 3000
|
|
37
|
+
```
|
|
38
|
+
|
|
29
39
|
## Build de Produção
|
|
30
40
|
|
|
31
41
|
Gere um SPA otimizado para deploy:
|
|
32
42
|
|
|
33
43
|
```bash
|
|
34
|
-
npx
|
|
44
|
+
npx docsector build
|
|
35
45
|
```
|
|
36
46
|
|
|
37
47
|
O output fica em `dist/spa/` — pronto para deploy em qualquer hosting estático.
|
|
38
48
|
|
|
49
|
+
Para visualizar a build de produção localmente:
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
npx docsector serve
|
|
53
|
+
```
|
|
54
|
+
|
|
39
55
|
## Estrutura do Projeto
|
|
40
56
|
|
|
41
|
-
|
|
57
|
+
Após o `init`, seu projeto terá esta estrutura:
|
|
42
58
|
|
|
43
|
-
- `docsector.config.js` — Branding, links, idiomas
|
|
59
|
+
- `docsector.config.js` — Branding, links, idiomas, config do GitHub
|
|
60
|
+
- `quasar.config.js` — Wrapper fino usando `createQuasarConfig()` do pacote
|
|
61
|
+
- `index.html` — Ponto de entrada HTML com título e meta tags
|
|
44
62
|
- `src/pages/index.js` — Registro de páginas (rotas e metadata)
|
|
45
63
|
- `src/pages/guide/` — Páginas tipo guia (arquivos Markdown)
|
|
46
64
|
- `src/pages/manual/` — Páginas tipo manual (arquivos Markdown)
|
|
47
|
-
- `src/
|
|
48
|
-
- `src/
|
|
49
|
-
- `
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
- `src/boot/` — Boot files (store, i18n, QZoom, axios)
|
|
65
|
+
- `src/i18n/index.js` — Loader i18n usando `buildMessages()` do pacote
|
|
66
|
+
- `src/i18n/tags.hjson` — Palavras-chave de busca por rota e idioma
|
|
67
|
+
- `public/` — Assets estáticos (logo, favicon, imagens)
|
|
68
|
+
|
|
69
|
+
O motor de renderização (componentes, layouts, router, store, composables) fica dentro do pacote `@docsector/docsector-reader` — você só mantém seu conteúdo e configuração.
|
|
53
70
|
|
|
54
71
|
## Próximos Passos
|
|
55
72
|
|
|
56
73
|
- Configure o branding do seu projeto em **docsector.config.js**
|
|
57
74
|
- Defina suas páginas em **src/pages/index.js**
|
|
58
75
|
- Escreva sua documentação em **Markdown**
|
|
76
|
+
- Adicione palavras-chave de busca em **src/i18n/tags.hjson**
|
|
59
77
|
- Personalize temas e aparência
|