Nagging Penguin Matriarchs

    rollup-plugin-asciidoc

    1.0.4 • Public • Published

    Plugin to import Asciidoctor files using Rollup.

    Quickstart

    $ yarn add rollup-plugin-asciidoc --dev
    

    Add the plugin to Rollup configuration.

    rollup.config.js

    import asciidoc from 'rollup-plugin-asciidoc' 
    
    // ...
    
    plugins: [ 
                asciidoc(),
    ]
    • Import Asciidoc plugin

    • Plugins section in Rollup configuration

    Import an Asciidoc file in your source code.

    example.js

    import post from 'post.adoc' 
    
    console.log(post) 
    • Import Asciidoc file.

    • Log the content.

    It will output something like:

    {
      meta: {
        title: "Post title",
        date: "2019-11-11"
      },
      html: "<p>Such a post!</p>"
    }

    Install

    npm i rollup-plugin-asciidoc

    DownloadsWeekly Downloads

    0

    Version

    1.0.4

    License

    MIT

    Unpacked Size

    8.18 kB

    Total Files

    9

    Last publish

    Collaborators

    • carlsa