Skip to content

Commit 0f78d47

Browse files
mattbaileyukandrew-coleman
authored andcommitted
Some doc updates (#322)
* Update numeric-functions.md * Update contributing.md * Update contributing.md
1 parent 9cde14e commit 0f78d47

File tree

2 files changed

+13
-10
lines changed

2 files changed

+13
-10
lines changed

docs/contributing.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,25 +6,26 @@ sidebar_label: Community and Contributing
66

77
## General questions - StackOverflow
88

9-
Tagged with `jsonata`
9+
See questions [tagged with `jsonata`](https://stackoverflow.com/questions/tagged/jsonata)
1010

1111
## Bugs reporting
1212

13-
Bugs, suspected bugs, odd behaviour.
14-
Open a GitHub issue - preferably contain link to exerciser
13+
For bugs, suspected bugs and any other odd behaviour, please [open a GitHub issue](https://github.com/jsonata-js/jsonata/issues/new). Preferably include a link to the [JSONata exerciser](http://try.jsonata.org/) which includes your source data and expression. This can be done using the "Share" function in the top-right.
1514

1615
## Enhancement requests
1716

18-
Open a GitHub issue
17+
For any enhacement request, please [open a GitHub issue](https://github.com/jsonata-js/jsonata/issues/new)
1918

2019
## Cloning and building
2120

21+
To contribute changes to the JSONata code (or documentation), [fork the `jsonata` repository](https://help.github.com/en/articles/fork-a-repo), [clone the fork](https://help.github.com/en/articles/cloning-a-repository) and make your changes. You can then contribute back to the main project by opening a pull request, ensuring you have maintained code coverage.
22+
2223
## JSONata conformance test suite
2324

24-
The purpose, the structure, how to write a test suite driver
25+
_This section is incomplete_
2526

26-
The implementation specific tests - mocha
27+
The tests use the `mocha` framework and can be executed by running `npm t` or `npm run test` which also runs `eslint` linting to check the code meets the formatting requirements of the project.
2728

2829
## Documentation
2930

30-
Open source, how to contribute
31+
Documentation, such as this, is all part of the `jsonata` main GitHub project. It is written in Markdown, and updates (improvements, fix, etc.) are welcome via pull requests.

docs/numeric-functions.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ Casts the `number` to a string and formats it to an integer represented in the n
142142

143143
__Examples__
144144

145-
- `$formatBase(100, 2)` => "1100100"
145+
- `$formatBase(100, 2)` => `"1100100"`
146146
- `$formatBase(2555, 16)` => `"9fb"`
147147

148148

@@ -155,7 +155,8 @@ The behaviour of this function is consistent with the two-argument version of th
155155

156156
__Examples__
157157

158-
-
158+
- `$formatInteger(2789, 'w')` => `"two thousand, seven hundred and eighty-nine"`
159+
- `$formatInteger(1999, 'I')` => `"MCMXCIX"`
159160

160161
## `$parseInteger()`
161162
__Signature:__ `$parseInteger(string, picture)`
@@ -166,4 +167,5 @@ function for parsing integers, this capability has been added to JSONata.
166167

167168
__Examples__
168169

169-
-
170+
- `$parseInteger("twelve thousand, four hundred and seventy-six", 'w')` => `12476`
171+
- `$parseInteger('12,345,678', '#,##0')` => `12345678`

0 commit comments

Comments
 (0)