0.0.5 • Published 7 months ago

ngx-textile v0.0.5

Weekly downloads
-
License
-
Repository
github
Last release
7 months ago

NgxTextile

Use Textile markup language in your Angular project, using textile-js

Within a template

import { Component } from '@angular/core';
import { TextilePipe } from 'ngx-textile';

@Component({
  imports: [TextilePipe],
  template: `
    <div [innerHTML]="text | textile"></div>
  `,
})
export class TestTextileComponent {
    text = 'a _shorthand syntax_ used to generate valid HTML'
}

With the service

import { Component, inject } from '@angular/core';
import { NgxTextileService } from 'ngx-textile';

@Component({
  template: `
    <div [innerHTML]="text"></div>
  `,
})
export class TestTextileComponent {
    #textile = inject(NgxTextileService)
    text = this.#textile.parse('a _shorthand syntax_ used to generate valid HTML')
}

Install

npm i ngx-textile

0.0.5

7 months ago

0.0.3

10 months ago

0.0.2

10 months ago

0.0.1

10 months ago