primate 0.9.0 → 0.9.1
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/README.md +5 -16
- package/README.template.md +4 -15
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -127,7 +127,7 @@ export default router => {
|
|
|
127
127
|
|
|
128
128
|
## Routing
|
|
129
129
|
|
|
130
|
-
Routes map requests to responses.
|
|
130
|
+
Routes map requests to responses. Routes are loaded from `routes`.
|
|
131
131
|
|
|
132
132
|
The order in which routes are declared is irrelevant. Redeclaring a route
|
|
133
133
|
(same pathname and same HTTP verb) throws a `RouteError`.
|
|
@@ -189,7 +189,7 @@ export default router => {
|
|
|
189
189
|
router.get("/user/view/_id", request => request.path[2]);
|
|
190
190
|
|
|
191
191
|
// can be combined with named groups
|
|
192
|
-
router.alias("_name", "(
|
|
192
|
+
router.alias("_name", "(?<name>[a-z])+");
|
|
193
193
|
|
|
194
194
|
// will return name if matched, 404 otherwise
|
|
195
195
|
router.get("/user/view/_name", request => request.named.name);
|
|
@@ -223,10 +223,8 @@ export default router => {
|
|
|
223
223
|
|
|
224
224
|
## Domains
|
|
225
225
|
|
|
226
|
-
Domains represent a collection in a store
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
A collection is primarily described using the class `fields` property.
|
|
226
|
+
Domains represent a collection in a store, primarily with the class `fields`
|
|
227
|
+
property.
|
|
230
228
|
|
|
231
229
|
### Fields
|
|
232
230
|
|
|
@@ -299,7 +297,7 @@ export default class User extends Domain {
|
|
|
299
297
|
Stores interface data. Primate comes with volatile in-memory store used as a
|
|
300
298
|
default. Other stores can be imported as modules.
|
|
301
299
|
|
|
302
|
-
|
|
300
|
+
Stores are loaded from `stores`.
|
|
303
301
|
|
|
304
302
|
### Resources
|
|
305
303
|
|
|
@@ -309,12 +307,3 @@ All stores are loaded from `stores`.
|
|
|
309
307
|
## License
|
|
310
308
|
|
|
311
309
|
MIT
|
|
312
|
-
|
|
313
|
-
[getting-started]: https://primatejs.com/getting-started
|
|
314
|
-
[source-code]: https://github.com/primatejs/primate
|
|
315
|
-
[issues]: https://github.com/primatejs/primate/issues
|
|
316
|
-
[primate-file-store]: https://npmjs.com/primate-file-store
|
|
317
|
-
[primate-json-store]: https://npmjs.com/primate-json-store
|
|
318
|
-
[primate-mongodb-store]: https://npmjs.com/primate-mongodb-store
|
|
319
|
-
[primate-react]: https://github.com/primatejs/primate-react
|
|
320
|
-
[primate-vue]: https://github.com/primatejs/primate-vue
|
package/README.template.md
CHANGED
|
@@ -80,7 +80,7 @@ Serve the component in your route
|
|
|
80
80
|
|
|
81
81
|
## Routing
|
|
82
82
|
|
|
83
|
-
Routes map requests to responses.
|
|
83
|
+
Routes map requests to responses. Routes are loaded from `routes`.
|
|
84
84
|
|
|
85
85
|
The order in which routes are declared is irrelevant. Redeclaring a route
|
|
86
86
|
(same pathname and same HTTP verb) throws a `RouteError`.
|
|
@@ -123,10 +123,8 @@ The order in which routes are declared is irrelevant. Redeclaring a route
|
|
|
123
123
|
|
|
124
124
|
## Domains
|
|
125
125
|
|
|
126
|
-
Domains represent a collection in a store
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
A collection is primarily described using the class `fields` property.
|
|
126
|
+
Domains represent a collection in a store, primarily with the class `fields`
|
|
127
|
+
property.
|
|
130
128
|
|
|
131
129
|
### Fields
|
|
132
130
|
|
|
@@ -160,7 +158,7 @@ aside from the type.
|
|
|
160
158
|
Stores interface data. Primate comes with volatile in-memory store used as a
|
|
161
159
|
default. Other stores can be imported as modules.
|
|
162
160
|
|
|
163
|
-
|
|
161
|
+
Stores are loaded from `stores`.
|
|
164
162
|
|
|
165
163
|
### Resources
|
|
166
164
|
|
|
@@ -170,12 +168,3 @@ All stores are loaded from `stores`.
|
|
|
170
168
|
## License
|
|
171
169
|
|
|
172
170
|
MIT
|
|
173
|
-
|
|
174
|
-
[getting-started]: https://primatejs.com/getting-started
|
|
175
|
-
[source-code]: https://github.com/primatejs/primate
|
|
176
|
-
[issues]: https://github.com/primatejs/primate/issues
|
|
177
|
-
[primate-file-store]: https://npmjs.com/primate-file-store
|
|
178
|
-
[primate-json-store]: https://npmjs.com/primate-json-store
|
|
179
|
-
[primate-mongodb-store]: https://npmjs.com/primate-mongodb-store
|
|
180
|
-
[primate-react]: https://github.com/primatejs/primate-react
|
|
181
|
-
[primate-vue]: https://github.com/primatejs/primate-vue
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "primate",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.1",
|
|
4
4
|
"author": "Terrablue <terrablue@proton.me>",
|
|
5
5
|
"homepage": "https://primatejs.com",
|
|
6
6
|
"bugs": "https://github.com/primatejs/primate/issues",
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"description": "Primal JavaScript framework",
|
|
9
9
|
"license": "MIT",
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"runtime-compat": "
|
|
11
|
+
"runtime-compat": "^0.12.2"
|
|
12
12
|
},
|
|
13
13
|
"bin": "bin/primate.js",
|
|
14
14
|
"devDependencies": {
|