alinea 0.2.7 → 0.2.8
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 +25 -21
- package/readme.md +76 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"bin": "./dist/cli.js",
|
|
3
3
|
"name": "alinea",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.8",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -13,7 +13,8 @@
|
|
|
13
13
|
"./*": "./dist/*.js"
|
|
14
14
|
},
|
|
15
15
|
"files": [
|
|
16
|
-
"dist"
|
|
16
|
+
"dist",
|
|
17
|
+
"readme.md"
|
|
17
18
|
],
|
|
18
19
|
"sideEffects": [
|
|
19
20
|
"./dist/cli.js"
|
|
@@ -26,25 +27,28 @@
|
|
|
26
27
|
}
|
|
27
28
|
},
|
|
28
29
|
"dependencies": {
|
|
29
|
-
"@alinea/cli": "0.2.
|
|
30
|
-
"@alinea/cloud": "0.2.
|
|
31
|
-
"@alinea/core": "0.2.
|
|
32
|
-
"@alinea/css": "0.2.
|
|
33
|
-
"@alinea/dashboard": "0.2.
|
|
34
|
-
"@alinea/input.check": "0.2.
|
|
35
|
-
"@alinea/input.code": "0.2.
|
|
36
|
-
"@alinea/input.date": "0.2.
|
|
37
|
-
"@alinea/input.json": "0.2.
|
|
38
|
-
"@alinea/input.link": "0.2.
|
|
39
|
-
"@alinea/input.list": "0.2.
|
|
40
|
-
"@alinea/input.number": "0.2.
|
|
41
|
-
"@alinea/input.object": "0.2.
|
|
42
|
-
"@alinea/input.path": "0.2.
|
|
43
|
-
"@alinea/input.richtext": "0.2.
|
|
44
|
-
"@alinea/input.select": "0.2.
|
|
45
|
-
"@alinea/input.tabs": "0.2.
|
|
46
|
-
"@alinea/input.text": "0.2.
|
|
30
|
+
"@alinea/cli": "0.2.8",
|
|
31
|
+
"@alinea/cloud": "0.2.8",
|
|
32
|
+
"@alinea/core": "0.2.8",
|
|
33
|
+
"@alinea/css": "0.2.8",
|
|
34
|
+
"@alinea/dashboard": "0.2.8",
|
|
35
|
+
"@alinea/input.check": "0.2.8",
|
|
36
|
+
"@alinea/input.code": "0.2.8",
|
|
37
|
+
"@alinea/input.date": "0.2.8",
|
|
38
|
+
"@alinea/input.json": "0.2.8",
|
|
39
|
+
"@alinea/input.link": "0.2.8",
|
|
40
|
+
"@alinea/input.list": "0.2.8",
|
|
41
|
+
"@alinea/input.number": "0.2.8",
|
|
42
|
+
"@alinea/input.object": "0.2.8",
|
|
43
|
+
"@alinea/input.path": "0.2.8",
|
|
44
|
+
"@alinea/input.richtext": "0.2.8",
|
|
45
|
+
"@alinea/input.select": "0.2.8",
|
|
46
|
+
"@alinea/input.tabs": "0.2.8",
|
|
47
|
+
"@alinea/input.text": "0.2.8",
|
|
47
48
|
"@alinea/sqlite-wasm": "^0.1.11",
|
|
48
|
-
"@alinea/ui": "0.2.
|
|
49
|
+
"@alinea/ui": "0.2.8"
|
|
50
|
+
},
|
|
51
|
+
"scripts": {
|
|
52
|
+
"prepare": "cp ../../readme.md readme.md"
|
|
49
53
|
}
|
|
50
54
|
}
|
package/readme.md
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
[](https://npmjs.org/package/alinea)
|
|
2
|
+
[](https://packagephobia.com/result?p=alinea)
|
|
3
|
+
|
|
4
|
+
# [](https://alinea.sh)
|
|
5
|
+
|
|
6
|
+
> *Current status*: expect alpha software and out of date docs.
|
|
7
|
+
|
|
8
|
+
Alinea is a modern content management system.
|
|
9
|
+
|
|
10
|
+
- Content is stored in flat files and committed to your repository
|
|
11
|
+
- Content is easily queryable through an in-memory SQLite database
|
|
12
|
+
- Content is fully typed
|
|
13
|
+
|
|
14
|
+
## Get started
|
|
15
|
+
|
|
16
|
+
Install alinea in your project directory
|
|
17
|
+
|
|
18
|
+
```sh
|
|
19
|
+
npm install alinea
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Initialize alinea's config file
|
|
23
|
+
|
|
24
|
+
```sh
|
|
25
|
+
npx alinea init
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Open the dashboard to have a look around
|
|
29
|
+
|
|
30
|
+
```sh
|
|
31
|
+
npx alinea serve
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
[Start configuring types and fields →](https://alinea.sh/docs/configuration/intro)
|
|
35
|
+
|
|
36
|
+
## Configure
|
|
37
|
+
|
|
38
|
+
Configure alinea in `alinea.config.tsx`
|
|
39
|
+
|
|
40
|
+
````tsx
|
|
41
|
+
const BlogPost = alinea.type('Blog post', {
|
|
42
|
+
title: alinea.text('Blog entry title'),
|
|
43
|
+
body: alinea.richText('Body text')
|
|
44
|
+
})
|
|
45
|
+
````
|
|
46
|
+
|
|
47
|
+
[Type options and fields →](https://alinea.sh/docs/configuration/type)
|
|
48
|
+
|
|
49
|
+
## Query
|
|
50
|
+
|
|
51
|
+
Retrieve content fully-typed and filter, order, limit and join as needed.
|
|
52
|
+
Select only the fields you need.
|
|
53
|
+
|
|
54
|
+
````tsx
|
|
55
|
+
import {initPages} from '@alinea/content/myWorkspace/pages.js'
|
|
56
|
+
const pages = initPages()
|
|
57
|
+
console.log(
|
|
58
|
+
await pages
|
|
59
|
+
.whereType('BlogPost')
|
|
60
|
+
.where(post => post.author.is('Me'))
|
|
61
|
+
.select(post => ({title: post.title}))
|
|
62
|
+
)
|
|
63
|
+
````
|
|
64
|
+
|
|
65
|
+
[See the full api →](https://alinea.sh/docs/content/pages)
|
|
66
|
+
|
|
67
|
+
Content is available during static site generation and when server side querying.
|
|
68
|
+
Content is bundled with your code and can be queried with zero network overhead.
|
|
69
|
+
|
|
70
|
+
[How alinea bundles content →](https://alinea.sh/docs/content/introduction)
|
|
71
|
+
|
|
72
|
+
## Deploy anywhere
|
|
73
|
+
|
|
74
|
+
Alinea supports custom backends that can be hosted as a simple Node.js process or on serverless runtimes.
|
|
75
|
+
|
|
76
|
+
[Setup your backend →](https://alinea.sh/docs/deploy/backends)
|