https://github.com/rkhayyat/nativescript-hijri
Nativescript plugin to convert from gregorian to hijri date
https://github.com/rkhayyat/nativescript-hijri
hijri nativescript plugin
Last synced: about 2 months ago
JSON representation
Nativescript plugin to convert from gregorian to hijri date
- Host: GitHub
- URL: https://github.com/rkhayyat/nativescript-hijri
- Owner: rkhayyat
- License: other
- Created: 2017-09-05T22:15:19.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2017-10-10T07:14:04.000Z (over 7 years ago)
- Last Synced: 2025-03-25T23:41:38.646Z (2 months ago)
- Topics: hijri, nativescript, plugin
- Language: TypeScript
- Homepage:
- Size: 1.96 MB
- Stars: 8
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://www.npmjs.com/package/nativescript-hijri)
[](https://www.npmjs.com/package/nativescript-hijri)
[](https://twitter.com/rakhayyat)[](https://nodei.co/npm/nativescript-hijri/)
# Nativescript Hijri plugin
This plugin is inspired by https://github.com/arabiaweather/hijri-date# Nativescript-hijri
Hijri plugin allow you to convert gregorian date to islamic hijri date.
![]()
## Installation
```javascript
tns plugin add nativescript-hijri
```## Usage
## Typescript NativeScript
### main-view-model
```typescript
import {Observable} from 'data/observable';
import {Hijri, islamicDateObject} from 'nativescript-hijri';export class HelloWorldModel extends Observable {
public message: string;
private hijri: Hijri;constructor() {
super();this.hijri = new Hijri(new Date,0);
this.message = this.hijri.hijri_en.dayOfWeekText;
console.dir(this.hijri.hijri_en);}
}
```## API
### Methods
| Method | Return | Description |
| --- | --- | --- |
| `hijri_ar` | `Object:islamicDateObject` | Accepts 2 Arguments Date , Date Adjustment by days.
return Object of islamicDateObject where day and month are written in arabic alphabet.|
| `hijri_en`| `Object:islamicDateObject` | Accepts 2 Arguments Date , Date Adjustment by days.
return Object of islamicDateObject where day and month are written in English alphabet. |## NativeBaguette 🥖
[
](https://github.com/rkhayyat) |
:---: |
[rkhayyat](https://github.com/rkhayyat) |