Skip to content

Commit 7676b50

Browse files
chore: update readme
1 parent fb1007e commit 7676b50

File tree

3 files changed

+28
-2
lines changed

3 files changed

+28
-2
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
{
22
"name": "classcharts-api",
3-
"version": "0.0.1",
3+
"version": "0.0.2",
44
"description": "",
55
"repository": {
66
"url": "https://github.com/jamesatjaminit/classcharts-api"
77
},
88
"main": "./index.js",
99
"scripts": {
10-
"prepublishOnly": "pnpm tsc && node dist/release.js",
10+
"buildReady": "pnpm tsc && node dist/release.js",
1111
"generateDocs": "pnpm typedoc --entryPointStrategy expand ./src"
1212
},
1313
"author": "",

readme.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,28 @@
11
# Classcharts API
22

33
A very WIP client for the classcharts API
4+
5+
[Documentation](https://jamesatjaminit.github.io/classcharts-api/index.html)
6+
7+
# Examples
8+
9+
```typescript
10+
import { ClasschartsClient } from 'classcharts-api'
11+
async function main() {
12+
const client = new ClasschartsClient('classchartsCode', '01/1/2000')
13+
await client.init()
14+
console.log(
15+
await client.getBehaviour({
16+
displayDate: 'due_date',
17+
fromDate: '20/01/2000',
18+
toDate: '01/02/2000',
19+
})
20+
)
21+
console.log(await client.getActivity(null))
22+
console.log(await client.getStudentInfo())
23+
console.log(await client.getActivity(null))
24+
console.log(await client.getActivity(null))
25+
}
26+
27+
main()
28+
```

src/release.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ function main() {
2323
Buffer.from(sourceObj.version, 'utf-8')
2424
)
2525
fs.copyFileSync(__dirname + '/../.npmignore', __dirname + '/.npmignore')
26+
fs.copyFileSync(__dirname + '/../README.MD', __dirname + '/README.MD')
2627
}
2728

2829
main()

0 commit comments

Comments
 (0)