2.0.0 • Published 7 years ago
bbcode-converter-pipe v2.0.0
BBcode converter angular 2+ pipe
Convert plain bb code to html code with pipe based on Js body parser.
Installation
Use npm to install the package
npm i bbcode-converter-pipe --saveor
yarn add bbcode-converter-pipe You need also add into your module
declarationstheBbcodeConverterPipein order to add all of the pipes.import {BbcodeConverterPipe} from 'bbcode-converter-pipe'; @NgModule({ // ... declarations: [ // ... BbcodeConverterPipe ] })
Usage
export class AppComponent {
text = 'I would like to [b]emphasize[/b] this';
}<span [innerHTML]="text | bbcode"></span>
<!-- Output: <span>I would like to <strong>emphasize</strong> this</span> -->Contributing
- Before adding any new feature or a fix make sure to open an issue first!
Make sure you have angular-cli & karma installed globally.
npm install -g angular-cli karmaClone the project, and install dependencies.
git clone https://github.com/call-me-adas/angular-converter-bbcode-pipe.git
npm installCreate a new branch
git checkout -b feat/someFeatureAdd tests & make sure everything is running properly
npm testCommit & push, and make a pull request!
Further help
To get more help on the Angular CLI use ng help or go check out the Angular CLI README.