https://github.com/kagawagao/nationalhighschooldata-cn
National high school data
https://github.com/kagawagao/nationalhighschooldata-cn
Last synced: 3 months ago
JSON representation
National high school data
- Host: GitHub
- URL: https://github.com/kagawagao/nationalhighschooldata-cn
- Owner: kagawagao
- License: mit
- Created: 2016-03-23T12:55:01.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-03-31T07:12:24.000Z (about 9 years ago)
- Last Synced: 2025-02-23T08:20:02.114Z (4 months ago)
- Language: JavaScript
- Size: 402 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# NationalHighSchoolData-cn
> National high school data of China# Install
```bash
$ npm install national-high-school --save
```# Use
```javascript
import NationalHighSchoolData from 'national-high-school'
```# API
- Get all schools```javascript
/**
* get all schools
* @return {array} schools - school list
*/
NationalHighSchoolData.schools()
```- Get school by school code
```javascript
/**
* get school by school code
* @param {string || number} code - school code
* @return {object} school - school instance
*/
NationalHighSchoolData.getByCode(code)
```- Get school by area code
```javascript
/**
* get schools by area code
* @param {string || number} areaCode - area code
* @return {array} schools - school list
*/
NationalHighSchoolData.getByAreaCode(areaCode)
```
- Search school by name```javascript
/**
* search school by name
* @param {string} name - school name
* @return {array} schools - school list
*/
NationalHighSchoolData.searchByName(name)
```