mirror of
https://github.com/classchartsapi/classcharts-api-js.git
synced 2026-05-14 11:58:13 +00:00
chore: update readme
This commit is contained in:
parent
fb1007e71c
commit
7676b50ccf
3 changed files with 28 additions and 2 deletions
|
|
@ -1,13 +1,13 @@
|
||||||
{
|
{
|
||||||
"name": "classcharts-api",
|
"name": "classcharts-api",
|
||||||
"version": "0.0.1",
|
"version": "0.0.2",
|
||||||
"description": "",
|
"description": "",
|
||||||
"repository": {
|
"repository": {
|
||||||
"url": "https://github.com/jamesatjaminit/classcharts-api"
|
"url": "https://github.com/jamesatjaminit/classcharts-api"
|
||||||
},
|
},
|
||||||
"main": "./index.js",
|
"main": "./index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepublishOnly": "pnpm tsc && node dist/release.js",
|
"buildReady": "pnpm tsc && node dist/release.js",
|
||||||
"generateDocs": "pnpm typedoc --entryPointStrategy expand ./src"
|
"generateDocs": "pnpm typedoc --entryPointStrategy expand ./src"
|
||||||
},
|
},
|
||||||
"author": "",
|
"author": "",
|
||||||
|
|
|
||||||
25
readme.md
25
readme.md
|
|
@ -1,3 +1,28 @@
|
||||||
# Classcharts API
|
# Classcharts API
|
||||||
|
|
||||||
A very WIP client for the classcharts API
|
A very WIP client for the classcharts API
|
||||||
|
|
||||||
|
[Documentation](https://jamesatjaminit.github.io/classcharts-api/index.html)
|
||||||
|
|
||||||
|
# Examples
|
||||||
|
|
||||||
|
```typescript
|
||||||
|
import { ClasschartsClient } from 'classcharts-api'
|
||||||
|
async function main() {
|
||||||
|
const client = new ClasschartsClient('classchartsCode', '01/1/2000')
|
||||||
|
await client.init()
|
||||||
|
console.log(
|
||||||
|
await client.getBehaviour({
|
||||||
|
displayDate: 'due_date',
|
||||||
|
fromDate: '20/01/2000',
|
||||||
|
toDate: '01/02/2000',
|
||||||
|
})
|
||||||
|
)
|
||||||
|
console.log(await client.getActivity(null))
|
||||||
|
console.log(await client.getStudentInfo())
|
||||||
|
console.log(await client.getActivity(null))
|
||||||
|
console.log(await client.getActivity(null))
|
||||||
|
}
|
||||||
|
|
||||||
|
main()
|
||||||
|
```
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,7 @@ function main() {
|
||||||
Buffer.from(sourceObj.version, 'utf-8')
|
Buffer.from(sourceObj.version, 'utf-8')
|
||||||
)
|
)
|
||||||
fs.copyFileSync(__dirname + '/../.npmignore', __dirname + '/.npmignore')
|
fs.copyFileSync(__dirname + '/../.npmignore', __dirname + '/.npmignore')
|
||||||
|
fs.copyFileSync(__dirname + '/../README.MD', __dirname + '/README.MD')
|
||||||
}
|
}
|
||||||
|
|
||||||
main()
|
main()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue