-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fb92dce
commit b42c5f4
Showing
2 changed files
with
31 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,38 @@ | ||
# NativeScript Email | ||
|
||
An Email module for use in NativeScript apps. | ||
An Email plugin for use in your NativeScript app. | ||
You can use it to compose emails, edit the draft manually, and send it. | ||
|
||
## Installation | ||
From the command prompt go to your app's `app` folder and execute: | ||
Run the following command from the root of your project: | ||
|
||
``` | ||
npm install nativescript-email | ||
tns plugin add nativescript-email | ||
``` | ||
|
||
## Usage | ||
|
||
### available | ||
To use this plugin you must first require() it: | ||
|
||
```js | ||
var email = require( "./node_modules/nativescript-email/email" ); | ||
var email = require("nativescript-email"); | ||
``` | ||
|
||
### available | ||
|
||
```js | ||
email.available().then(function(avail) { | ||
alert("Avail? " + avail); | ||
alert("Available? " + avail); | ||
}) | ||
``` | ||
|
||
### compose | ||
```js | ||
var email = require( "./node_modules/nativescript-email/email" ); | ||
|
||
email.compose({ | ||
subject: "Yo", | ||
body: "Hello <strong>dude</strong> :)", | ||
to: ['[email protected]', '[email protected]'], | ||
cc: ['[email protected]'], | ||
cc: ['[email protected]'], | ||
bcc: ['[email protected]', '[email protected]'] | ||
}).then(function(r) { | ||
console.log("email closed"); | ||
|
@@ -39,8 +41,7 @@ npm install nativescript-email | |
|
||
## Known issues | ||
On Android, you can pass an array of to/cc/bcc, but only the first one is added. | ||
Should be able to fix that in a future release. | ||
|
||
## Future work | ||
Add attachment support | ||
|
||
Fix the known issues :) | ||
Add attachment support |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,28 @@ | ||
{ | ||
"name": "nativescript-email", | ||
"version": "1.0.0", | ||
"description": "An Email module for use in NativeScript apps", | ||
"version": "1.1.0", | ||
"description": "Email plugin for your NativeScript app", | ||
"main": "email.js", | ||
"nativescript": { | ||
"platforms": { | ||
"ios": "1.1.0", | ||
"android": "1.1.0" | ||
} | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/eddyverbruggen/nativescript-email.git" | ||
}, | ||
"keywords": [ | ||
"NativeScript" | ||
"NativeScript", | ||
"Mail", | ||
"Email", | ||
"Draft", | ||
"Compose", | ||
"MailComposer" | ||
], | ||
"author": { | ||
"name": "Eddy Verbruggen", | ||
"email": "[email protected]", | ||
"url": "http://x-services.nl/" | ||
}, | ||
"license": { | ||
"type": "MIT", | ||
"url": "https://github.com/eddyverbruggen/nativescript-email/blob/master/LICENSE" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/eddyverbruggen/nativescript-email/issues" | ||
}, | ||
"homepage": "https://github.com/eddyverbruggen/nativescript-email", | ||
"readmeFilename": "README.md" | ||
"author": "Eddy Verbruggen <[email protected]> (https://github.com/EddyVerbruggen)", | ||
"license": "MIT", | ||
"bugs": "https://github.com/eddyverbruggen/nativescript-email/issues", | ||
"homepage": "https://github.com/eddyverbruggen/nativescript-email" | ||
} |