Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/thinkhr-code/ember-cli-ahoy
Shim for ahoy.js
https://github.com/thinkhr-code/ember-cli-ahoy
addon emberjs mammothhr
Last synced: 7 days ago
JSON representation
Shim for ahoy.js
- Host: GitHub
- URL: https://github.com/thinkhr-code/ember-cli-ahoy
- Owner: thinkhr-code
- License: mit
- Created: 2016-04-27T15:57:38.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2022-12-06T22:18:33.000Z (almost 2 years ago)
- Last Synced: 2024-09-22T13:02:08.075Z (11 days ago)
- Topics: addon, emberjs, mammothhr
- Language: JavaScript
- Size: 1.07 MB
- Stars: 0
- Watchers: 10
- Forks: 1
- Open Issues: 17
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
[![Build Status](https://travis-ci.org/MammothHR/ember-cli-ahoy.svg?branch=master)](https://travis-ci.org/MammothHR/ember-cli-ahoy)
# ember-cli-ahoy
Provides an ES6 module for using [ahoy.js](https://github.com/ankane/ahoy.js).
## Installation
* `ember install ember-cli-ahoy`
## Usage
* Shim
```
import Ahoy from 'ahoy';
```* As a service
```
import Component from 'ember-component';
import service from 'ember-service/inject';export default Component.extend({
ahoy: service(),didInsertElement() {
this.get('ahoy').trackView({
url: 'foo-bar'
});
}
});
```## Running Tests
* `npm test` (Runs `ember try:each` to test your addon against multiple Ember versions)
* `ember test`
* `ember test --server`## Building
* `ember build`
For more information on using ember-cli, visit [https://ember-cli.com/](https://ember-cli.com/).