@paris-ias/trees 2.0.8 → 2.0.9
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/dist/graphql/client/actions/query.get.actions.gql +1 -4
- package/dist/graphql/client/affiliations/query.get.affiliations.gql +1 -4
- package/dist/graphql/client/apps/query.get.apps.gql +1 -4
- package/dist/graphql/client/events/query.get.events.gql +1 -4
- package/dist/graphql/client/fellowships/query.get.fellowships.gql +1 -4
- package/dist/graphql/client/misc/query.get.disciplines.gql +1 -4
- package/dist/graphql/client/misc/query.get.tags.gql +1 -4
- package/dist/graphql/client/misc/query.search.all.gql +0 -5
- package/dist/graphql/client/news/query.get.news.gql +1 -4
- package/dist/graphql/client/people/query.get.users.gql +1 -4
- package/dist/graphql/client/projects/query.get.projects.gql +1 -4
- package/dist/graphql/client/publications/query.get.publications.gql +1 -4
- package/package.json +1 -1
- package/readme.md +9 -9
|
@@ -3,7 +3,6 @@ query search($appId: ID = "", $search: String = "", $lang: String = "en") {
|
|
|
3
3
|
people {
|
|
4
4
|
items {
|
|
5
5
|
firstname
|
|
6
|
-
id
|
|
7
6
|
image {
|
|
8
7
|
alt
|
|
9
8
|
backgroundColor
|
|
@@ -21,7 +20,6 @@ query search($appId: ID = "", $search: String = "", $lang: String = "en") {
|
|
|
21
20
|
projects {
|
|
22
21
|
items {
|
|
23
22
|
date
|
|
24
|
-
id
|
|
25
23
|
featured
|
|
26
24
|
name
|
|
27
25
|
image {
|
|
@@ -54,7 +52,6 @@ query search($appId: ID = "", $search: String = "", $lang: String = "en") {
|
|
|
54
52
|
license
|
|
55
53
|
url
|
|
56
54
|
}
|
|
57
|
-
id
|
|
58
55
|
date
|
|
59
56
|
slug
|
|
60
57
|
}
|
|
@@ -94,7 +91,6 @@ query search($appId: ID = "", $search: String = "", $lang: String = "en") {
|
|
|
94
91
|
fellowshipStart
|
|
95
92
|
fellowshipType
|
|
96
93
|
fellowshipStop
|
|
97
|
-
id
|
|
98
94
|
image {
|
|
99
95
|
alt
|
|
100
96
|
backgroundColor
|
|
@@ -115,7 +111,6 @@ query search($appId: ID = "", $search: String = "", $lang: String = "en") {
|
|
|
115
111
|
category
|
|
116
112
|
date
|
|
117
113
|
featured
|
|
118
|
-
id
|
|
119
114
|
image {
|
|
120
115
|
alt
|
|
121
116
|
backgroundColor
|
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -421,20 +421,20 @@ All generated tree exports are **deeply frozen** using `Object.freeze()`, ensuri
|
|
|
421
421
|
import { formPeople } from "@paris-ias/trees"
|
|
422
422
|
|
|
423
423
|
// ❌ All mutations are prevented
|
|
424
|
-
formPeople._defaults.firstname = "hacked"
|
|
425
|
-
formPeople.schema.firstname.label = "modified"
|
|
426
|
-
formPeople.newProperty = "value"
|
|
427
|
-
delete formPeople._defaults
|
|
424
|
+
formPeople._defaults.firstname = "hacked" // Fails silently (non-strict)
|
|
425
|
+
formPeople.schema.firstname.label = "modified" // TypeError in strict mode
|
|
426
|
+
formPeople.newProperty = "value" // Cannot extend frozen objects
|
|
427
|
+
delete formPeople._defaults // Cannot delete properties
|
|
428
428
|
|
|
429
429
|
// ✅ Safe to share across your application
|
|
430
430
|
const config1 = formPeople
|
|
431
431
|
const config2 = formPeople // Same reference, guaranteed unchanged
|
|
432
432
|
|
|
433
433
|
// ✅ Objects are frozen at all levels
|
|
434
|
-
Object.isFrozen(formPeople)
|
|
435
|
-
Object.isFrozen(formPeople._defaults)
|
|
436
|
-
Object.isFrozen(formPeople.schema)
|
|
437
|
-
Object.isFrozen(formPeople.schema.firstname)
|
|
434
|
+
Object.isFrozen(formPeople) // true
|
|
435
|
+
Object.isFrozen(formPeople._defaults) // true
|
|
436
|
+
Object.isFrozen(formPeople.schema) // true
|
|
437
|
+
Object.isFrozen(formPeople.schema.firstname) // true
|
|
438
438
|
```
|
|
439
439
|
|
|
440
440
|
### Full TypeScript Support
|
|
@@ -446,7 +446,7 @@ Complete type definitions are automatically generated for all exports:
|
|
|
446
446
|
import { formPeople, listPeople, type Form, type List } from "@paris-ias/trees"
|
|
447
447
|
|
|
448
448
|
// IDE autocomplete and type checking work perfectly
|
|
449
|
-
const firstname = formPeople.schema.firstname
|
|
449
|
+
const firstname = formPeople.schema.firstname // Fully typed
|
|
450
450
|
const defaultName = formPeople._defaults.firstname // Type: string | { en: string, fr: string }
|
|
451
451
|
|
|
452
452
|
// Type-safe development
|