@yci/custom-url-scheme
v1.0.0
Published
[![Build Status](https://travis-ci.org/yc-ionic/custom-url-scheme.svg?branch=master)](https://travis-ci.org/yc-ionic/custom-url-scheme.svg?branch=master) [![Coverage Status](https://coveralls.io/repos/github/yc-ionic/custom-url-scheme/badge.svg?branch=mas
Downloads
2
Readme
@yci/custom-url-scheme
Installation
- Install the Ionic plugin
npm i -S @yci/custom-url-scheme
- Install the cordova plugin written by EddyVerbruggen
- Add it to your app’s NgModule.
// Import your library
import { CustomUrlSchemeModule } from '@yci/custom-url-scheme';
@NgModule({
...
imports: [
...
// Specify your library as an import
CustomUrlSchemeModule.forRoot()
],
...
})
export class AppModule { }
Usage
Once your library is imported, you can use its service in your Angular application:
import { CustomUrlScheme } from '@yci/custom-url-scheme';
// ...
constructor(public cus: CustomUrlScheme) {
cus.add('myScheme')
.subscribe(x => {
console.log(x);
});
}
// ...
Methods
public add(urlScheme: string): Subject<IUrlScheme>;
Interfaces
interface IUrlScheme {
scheme: string;
path: string;
query: {
[x: string]: string;
};
}
Development
To generate all *.js
, *.d.ts
and *.metadata.json
files:
$ npm run build
License
MIT © Yu Chen