Skip to content
This repository was archived by the owner on Jul 9, 2020. It is now read-only.

Convert to provider to enable charmap configuration (+ .gitignore) #31

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
bower_components
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,17 @@ The `from` attribute is the name of the model in the current scope you want to
slugify. The `to` attribute is the name of the model you want to be
automatically updated with the slugification whenever `from` changes.

## Configuration

The `SlugProvider` provider enables you to override mappings.

```js
angular.module("myApp")
.config(function(SlugProvider) {
SlugProvider.charmap['å'] = 'aa'; // default: 'a'
});
```

## Tests

```bash
Expand Down
Loading