Skip to content

Commit

Permalink
sdk-v4: run Action for pull-request
Browse files Browse the repository at this point in the history
  • Loading branch information
xr0master committed Jan 28, 2024
1 parent a94a8bd commit c7214e3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
push:
branches: [ master, sdk-v4 ]
pull_request:
branches: [ master ]
branches: [ master, sdk-v4 ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand Down
18 changes: 12 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ Or manually:
```html
<script
type="text/javascript"
src="https://cdn.jsdelivr.net/npm/@emailjs/browser@4/dist/email.min.js"
></script>
src="https://cdn.jsdelivr.net/npm/@emailjs/browser@4/dist/email.min.js">
</script>
<script type="text/javascript">
(function () {
emailjs.init({
Expand All @@ -52,7 +52,7 @@ Or manually:

## Examples

**send email**
**Send the email using the customized send method**

```js
var templateParams = {
Expand All @@ -70,7 +70,7 @@ emailjs.send('YOUR_SERVICE_ID', 'YOUR_TEMPLATE_ID', templateParams).then(
);
```

**send form**
**Send the email from a form using the sendForm method**

```js
emailjs.sendForm('YOUR_SERVICE_ID', 'YOUR_TEMPLATE_ID', '#myForm').then(
Expand All @@ -83,7 +83,9 @@ emailjs.sendForm('YOUR_SERVICE_ID', 'YOUR_TEMPLATE_ID', '#myForm').then(
);
```

**Angular X / VueJS / ReactJS**
**Send the email using any modern framework**
\
**Angular X / VueJS / ReactJS / Svelte/ Other**

```js
import emailjs from '@emailjs/browser';
Expand Down Expand Up @@ -111,14 +113,16 @@ emailjs

**Options**

Options can be declared globally using the init method or locally as the fourth parameter of a function.
Options can be declared globally using the **init** method or locally as the fourth parameter of a function.
\
The local parameter will have higher priority than the global one.

| Name | Type | Description |
| --------- | ------ | ------------------------------------------------- |
| publicKey | String | The public key is required to invoke the command. |

**Declare global settings**

```js
import emailjs from '@emailjs/browser';

Expand All @@ -127,6 +131,8 @@ emailjs.init({
});
```

**Overwrite settings locally**

```js
import emailjs from '@emailjs/browser';

Expand Down

0 comments on commit c7214e3

Please sign in to comment.