Skip to content

Commit 9659eca

Browse files
committed
📝 update readme
1 parent d11a3db commit 9659eca

File tree

1 file changed

+14
-28
lines changed

1 file changed

+14
-28
lines changed

README.md

Lines changed: 14 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,3 @@
1-
<!--
2-
This README describes the package. If you publish this package to pub.dev,
3-
this README's contents appear on the landing page for your package.
4-
5-
For information about how to write a good package README, see the guide for
6-
[writing package pages](https://dart.dev/guides/libraries/writing-package-pages).
7-
8-
For general information about developing packages, see the Dart guide for
9-
[creating packages](https://dart.dev/guides/libraries/create-library-packages)
10-
and the Flutter guide for
11-
[developing packages and plugins](https://flutter.dev/developing-packages).
12-
-->
13-
141
[![Dart](https://img.shields.io/badge/dart-%230175C2.svg?logo=dart&logoColor=white)](https://dart.dev/)
152
[![pub badge](https://img.shields.io/pub/v/albiruni.svg)](https://pub.dev/packages/albiruni)
163
[![style: lints](https://img.shields.io/badge/style-lints-4BC0F5.svg)](https://pub.dev/packages/lints)
@@ -22,15 +9,15 @@ Thank you [**@PlashSpeed-Aiman**](https://github.com/PlashSpeed-Aiman) for the [
229
## Get Started
2310

2411
1. Run `dart pub get`
25-
2. Start development. Make sure to update/add the test file if needed. Run `dart test` to run test suite.
12+
2. Start development. Make sure to update/add the test file if needed. Run `dart test` to run the test suite.
2613

2714
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/iiumschedule/albiruni)
2815

2916
## Features
3017

3118
### Get a list of subjects offered
3219

33-
Fetch of subjects for Kuliyyah of Economics for semester 1, 2021/2022 session:
20+
Fetch subjects for the Kulliyyah of Economics for semester 1, 2021/2022 session:
3421

3522
```dart
3623
// Create albiruni instance
@@ -39,7 +26,7 @@ Albiruni albiruni = Albiruni(semester: 1, session: "2021/2022");
3926
var (subjects, totalPage) = await albiruni.fetch("ECONS");
4027
```
4128

42-
Supports both Undergraduate and Postgraduate studies. Pass the `StudyGrade.ug` (default) or `StudyGrade.pg`.
29+
Supports both Undergraduate and Postgraduate studies. Pass `StudyGrad.ug` (default) or `StudyGrad.pg`.
4330

4431
```dart
4532
Albiruni(semester: 1, session: "2022/2023", studyGrade: StudyGrad.pg);
@@ -53,17 +40,17 @@ Put the subject course code in the `course` parameter. The subject must be Albir
5340
fetch("ECONS", course: "ECON 1140");
5441
```
5542

56-
Here's some trick. Let's say you want to **filter** the courses for **third**-year subjects only, just provide the first digit and ignore the rest.
43+
Here's a trick: Let's say you want to **filter** the courses for **third**-year subjects only, just provide the first digit and ignore the rest.
5744

5845
```dart
5946
fetch("CCAC", course: "CCUB 3");
6047
```
6148

6249
### Albiruni-formatted
6350

64-
The course code **must** be in the following format: `ABCD 1234`. The first four characters are the subject code, and the last four characters are the subject number. The space is required. _In some cases, the course code format might be different but generally, it will look like this._
51+
The course code **must** be in the following format: `ABCD 1234`. The first four characters are the subject code, and the last four characters are the subject number. The space is required. _In some cases, the course code format might be different, but generally, it will look like this._
6552

66-
Lucky for you, `.toAlbiruniFormat()` extension method will properly format the string for you. Useful when you're receiving input from the users etc.
53+
Luckily, the `.toAlbiruniFormat()` extension method will properly format the string for you. Useful when you're receiving input from users, etc.
6754

6855
```dart
6956
var userInput = "ccub2621";
@@ -72,7 +59,7 @@ fetch("CCAC", course: userInput.toAlbiruniFormat()); // formatted: CCUB 2621
7259

7360
### JSON
7461

75-
Parse subject data from JSON to Dart object, use `fromJson()` constructor.
62+
To parse subject data from JSON to a Dart object, use the `fromJson()` constructor.
7663

7764
Example JSON:
7865

@@ -94,32 +81,32 @@ Example JSON:
9481
}
9582
```
9683

97-
Parse it like following:
84+
Parse it as follows:
9885

9986
```dart
10087
var data = <yourjsonstring>
10188
var subjects = Subject.fromJson(jsonDecode(data));
10289
```
10390

104-
Similarly, you can convert Dart object to JSON using `toJson()` method.
91+
Similarly, you can convert a Dart object to JSON using the `toJson()` method.
10592

106-
I think that's it for the basic usage of this library, of course, you can always discover more. You can drop your inquiries in [issues](https://github.com/iqfareez/albiruni/issues) if you have any. More examples can be found in the `/example` folder.
93+
That's it for the basic usage of this library. Of course, you can always discover more. You can drop your inquiries in [issues](https://github.com/iqfareez/albiruni/issues) if you have any. More examples can be found in the `/example` folder.
10794

10895
## Common issues
10996

11097
- XMLHttpRequest error or CORS error
11198

112-
**Update**: The proxy service has been shut down. I will remove the `useProxy` property in the few future release.
99+
**Update**: The proxy service has been shut down. I will remove the `useProxy` property in a future release.
113100

114-
Usually occurs if you're developing for the web. Set `useProxy` flag to **true**. This will add a proxy layer between the client and the albiruni server.
101+
This usually occurs if you're developing for the web. Set the `useProxy` flag to **true**. This will add a proxy layer between the client and the Albiruni server.
115102

116103
```dart
117104
fetch("ENGIN", course: "MCTE 3271", useProxy: true);
118105
```
119106

120107
- HandshakeException: [CERTIFICATE_VERIFY_FAILED](https://github.com/iqfareez/iium_schedule/issues/10) error.
121108

122-
This happens when the albiruni server has some [certificate issues](https://github.com/iqfareez/iium_schedule/issues/10#issuecomment-1086550494). Some clients might reject the requests. If you're in development, try [this answer from SO](https://stackoverflow.com/a/61312927/13617136).
109+
This happens when the Albiruni server has some [certificate issues](https://github.com/iqfareez/iium_schedule/issues/10#issuecomment-1086550494). Some clients might reject the requests. If you're in development, try [this answer from SO](https://stackoverflow.com/a/61312927/13617136).
123110

124111
## List of available kulliyyah (as of 8 October 2025)
125112

@@ -148,10 +135,9 @@ I think that's it for the basic usage of this library, of course, you can always
148135
| 20 | `KOS` | SCIENCE |
149136
| 21 | `SC4SH` | SEJAHTERA CENTRE FOR SUS |
150137

151-
This list of available kulliyyah might change over time, kindly refer to https://iiumschedule.iqfareez.com/docs/devs/albiruni#list-of-available-kulliyyah
138+
This list of available kulliyyah might change over time. Kindly refer to https://iiumschedule.iqfareez.com/docs/devs/albiruni#list-of-available-kulliyyah
152139

153140
## Related information
154141

155142
- [IIUM Course Schedule Portal](https://albiruni.iium.edu.my/myapps/StudentOnline/schedule1.php)
156143
- [IIUM Schedule App](https://iiumschedule.iqfareez.com)
157-
- Experimental: [albiruni-api](https://github.com/iqfareez/albiruni-api)

0 commit comments

Comments
 (0)