Skip to content

Commit 8539a49

Browse files
authored
Revert "GitBook: [master] 60 pages modified" (#133)
This reverts commit c68efa3.
1 parent f09a5f3 commit 8539a49

35 files changed

+333
-358
lines changed

CHANGELOG.md

Lines changed: 129 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,129 @@
1+
## 2.0.0 - 2020-03-31
2+
3+
Refactors:
4+
5+
- The whole part of schemas and attribute definitions was refactored
6+
- Tests are now run by Jest (and Electron for browser tests)
7+
- Prettier was added
8+
- Move to mono-repo
9+
10+
Enhancements
11+
12+
- Implement jest-structure assertions
13+
- It's possible to set custom getters e setters directly in the structure class
14+
- Allows to disable coercion
15+
16+
Breaking changes:
17+
18+
- Joi is updated to v16
19+
- Attribute path in validation _errors_ is an array instead of a string
20+
- Attribute path in validation _messages_ contains the whole path joined by '.'
21+
- The name used for the dynamic import should aways be the same as the name of its type or else a custom identifier must be used
22+
- Non-nullable attributes with value null will use default value the same way undefined does
23+
- Structure classes now have two methods to generically set and get the value of the attributes, `.get(attributeName)` and `.set(attributeName, attributeValue)`
24+
- Minimum Node version is now 10
25+
26+
Docs:
27+
28+
- Rename the term `type descriptor` to `attribute definition` in the docs and in the code
29+
- Reorganize and add more specific pages to docs
30+
31+
## 2.0.0-alpha.4 - 2020-03-21
32+
33+
- Publish only src folder for jest-structure
34+
35+
## 2.0.0-alpha.3 - 2020-03-20
36+
37+
- Reorganize md files
38+
39+
## 2.0.0-alpha.2 - 2020-03-19
40+
41+
- Invert symlinks
42+
43+
## 2.0.0-alpha.1 - 2020-03-19
44+
45+
- Add symlinks to md files to packages/structure
46+
47+
## 2.0.0-alpha.0 - 2020-03-19
48+
49+
Refactors:
50+
51+
- The whole part of schemas and attribute definitions was refactored
52+
- Tests are now run by Jest (and Electron for browser tests)
53+
- Prettier was added
54+
- Move to mono-repo
55+
56+
Enhancements
57+
58+
- Implement jest-structure assertions
59+
- It's possible to set custom getters e setters directly in the structure class
60+
61+
Breaking changes:
62+
63+
- Joi is updated to v16
64+
- Attribute path in validation _errors_ is an array instead of a string
65+
- Attribute path in validation _messages_ contains the whole path joined by '.'
66+
- The name used for the dynamic import should aways be the same as the name of its type or else a custom identifier must be used
67+
- Non-nullable attributes with value null will use default value the same way undefined does
68+
- Structure classes now have two methods to generically set and get the value of the attributes, `.get(attributeName)` and `.set(attributeName, attributeValue)`
69+
- Minimum Node version is now 10
70+
71+
## 1.8.0 - 2019-09-16
72+
73+
Enhancements:
74+
75+
- Add `unique` validation to arrays
76+
77+
## 1.7.0 - 2019-09-14
78+
79+
Enhancements:
80+
81+
- Add method to clone structures
82+
83+
## 1.6.0 - 2019-08-27
84+
85+
Enhancements:
86+
87+
- Allow custom error class to static mode
88+
89+
## 1.5.0 - 2019-07-08
90+
91+
Enhancements:
92+
93+
- Add `buildStrict` static method
94+
95+
## 1.4.0 - 2019-03-26
96+
97+
Enhancements:
98+
99+
- Add `nullable` option
100+
101+
## 1.3.2 - 2019-03-22
102+
103+
Fix:
104+
105+
- The actual instance is passed to the dynamic defaults
106+
107+
## 1.3.0 - 2018-03-23
108+
109+
Enhancements:
110+
111+
- When using default function to initialize attributes you can now refer to another attribute values to compose value
112+
113+
## 1.2.0 - 2017-02-01
114+
115+
Features:
116+
117+
- Allow circular reference on type definitions ([@talyssonoc](https://github.com/talyssonoc/structure/pull/30))
118+
119+
Enhancements:
120+
121+
- Make validation faster ([@talyssonoc](https://github.com/talyssonoc/structure/pull/28))
122+
123+
Dependencies update:
124+
125+
- Update joi from 9.2.0 to 10.2.0 ([@talyssonoc](https://github.com/talyssonoc/structure/pull/26))
126+
127+
## 1.1.0 - 2017-01-17
128+
129+
- Added static method `validate()` to structures ([@talyssonoc](https://github.com/talyssonoc/structure/pull/25))

changelog.md

Lines changed: 0 additions & 132 deletions
This file was deleted.

coercion/README.md

Lines changed: 0 additions & 16 deletions
This file was deleted.

contributing.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ In short: _Be nice_. Pay attention to the fact that Structure is free software,
88

99
## Opening issues
1010

11-
When opening an issue be descriptive about the bug or the feature suggestion, don't simply paste the error message on the issue title or description. Also, **provide code to simulate the bug**, we need to know the exact circumstances in which the bug occurs. Again, follow our [code of conduct](contributing.md#code-of-conduct).
11+
When opening an issue be descriptive about the bug or the feature suggestion, don't simply paste the error message on the issue title or description. Also, **provide code to simulate the bug**, we need to know the exact circumstances in which the bug occurs. Again, follow our [code of conduct](#code-of-conduct).
1212

1313
## Pull requests
1414

@@ -23,4 +23,3 @@ When opening a pull request to Structure, follow this steps:
2323
7. Write a complete description about the bug or the feature the pull request is about.
2424

2525
Be aware that we keep **100% of code coverage**, any change that makes the code coverage less than 100% covered will be requested to write more tests.
26-

docs/SUMMARY.md

Lines changed: 31 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,33 @@
11
# Table of contents
22

3-
* [Introduction](../packages/structure/README.md)
4-
* [Schema concept](../schema-concept/README.md)
5-
* [Shorthand and complete attribute definition](../schema-concept/shorthand-and-complete-attribute-definition.md)
6-
* [Circular reference](../schema-concept/circular-references-and-dynamic-types.md)
7-
* [Nullable attributes](../schema-concept/nullable-attributes.md)
8-
* [Custom setters and getters](../custom-setters-and-getters.md)
9-
* [Coercion](../coercion/README.md)
10-
* [Primitive type coercion](../coercion/primitive-type-coercion.md)
11-
* [Arrays coercion](../coercion/arrays-and-array-subclasses.md)
12-
* [Generic coercion](../coercion/generic-coercion.md)
13-
* [Recursive coercion](../coercion/recursive-coercion.md)
14-
* [Disabling coercion](../coercion/disabling-coercion.md)
15-
* [Validation](../validation/README.md)
16-
* [String validations](../validation/string-validations.md)
17-
* [Number validations](../validation/number-validations.md)
18-
* [Boolean validations](../validation/boolean-validations.md)
19-
* [Date validations](../validation/date-validations.md)
20-
* [Array validations](../validation/array-validations.md)
21-
* [Attribute reference](../validation/attribute-reference.md)
22-
* [Nested validations](../validation/nested-validations.md)
23-
* [Validate raw data](../validation/validate-raw-data.md)
24-
* [Strict mode](../strict-mode.md)
25-
* [Cloning an instance](../cloning.md)
26-
* [Serialization](../serialization.md)
27-
* [Testing](../testing.md)
28-
* [Battlecry generators](../battlecry-generators.md)
29-
* [Migrating from v1](../migrating-from-v1.md)
30-
* [Support and compatibility](../support.md)
31-
* [Changelog](../changelog.md)
32-
* [Contributing](../contributing.md)
33-
* [License](../license.md)
34-
* [GitHub](https://github.com/talyssonoc/structure)
35-
3+
- [Schema concept](schema-concept/README.md)
4+
- [Shorthand and complete attribute definition](schema-concept/shorthand-and-complete-attribute-definition.md)
5+
- [Circular reference](schema-concept/circular-references-and-dynamic-types.md)
6+
- [Nullable attributes](schema-concept/nullable-attributes.md)
7+
- [Custom setters and getters](custom-setters-and-getters.md)
8+
- [Coercion](coercion/README.md)
9+
- [Primitive type coercion](coercion/primitive-type-coercion.md)
10+
- [Arrays coercion](coercion/arrays-and-array-subclasses.md)
11+
- [Generic coercion](coercion/generic-coercion.md)
12+
- [Recursive coercion](coercion/recursive-coercion.md)
13+
- [Disabling coercion](coercion/disabling-coercion.md)
14+
- [Validation](validation/README.md)
15+
- [String validations](validation/string-validations.md)
16+
- [Number validations](validation/number-validations.md)
17+
- [Boolean validations](validation/boolean-validations.md)
18+
- [Date validations](validation/date-validations.md)
19+
- [Array validations](validation/array-validations.md)
20+
- [Attribute reference](validation/attribute-reference.md)
21+
- [Nested validations](validation/nested-validations.md)
22+
- [Validate raw data](validation/validate-raw-data.md)
23+
- [Strict mode](strict-mode.md)
24+
- [Cloning an instance](cloning.md)
25+
- [Serialization](serialization.md)
26+
- [Testing](testing.md)
27+
- [Battlecry generators](battlecry-generators.md)
28+
- [Migrating from v1](migrating-from-v1.md)
29+
- [Support and compatibility](support.md)
30+
- [Changelog](../CHANGELOG.md)
31+
- [Contributing](../contributing.md)
32+
- [License](../license.md)
33+
- [GitHub](https://github.com/talyssonoc/structure)
Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
# Battlecry generators
1+
# BattleCry generators
22

33
There are configurable [BattleCry](https://github.com/pedsmoreira/battlecry) generators ready to be downloaded and help scaffolding schema:
44

5-
```bash
5+
```sh
66
npm install -g battlecry
77
cry download generator talyssonoc/structure
88
cry g schema user name age:int:required cars:string[] favoriteBook:book friends:user[]:default :updateAge
99
```
1010

1111
Run `cry --help` to check more info about the generators available;
12-

0 commit comments

Comments
 (0)