2.0.0 • Published 5 years ago

bbcode-converter-pipe v2.0.0

Weekly downloads
8
License
MIT
Repository
github
Last release
5 years ago

BBcode converter angular 2+ pipe

Convert plain bb code to html code with pipe based on Js body parser.

Installation

  1. Use npm to install the package

    npm i bbcode-converter-pipe --save 

    or

  yarn add bbcode-converter-pipe 
  1. You need also add into your module declarations the BbcodeConverterPipe in 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 karma

Clone the project, and install dependencies.

git clone https://github.com/call-me-adas/angular-converter-bbcode-pipe.git
npm install

Create a new branch

git checkout -b feat/someFeature

Add tests & make sure everything is running properly

npm test

Commit & 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.

2.0.0

5 years ago

1.0.1

5 years ago