@comsoc/gatsby-mdast-copy-linked-files

0.2.0 • Public • Published

gatsby-remark-copy-linked-files

Copies files linked to from markdown to your public folder.

Install

npm install --save gatsby-remark-copy-linked-files

How to use

// In your gatsby-config.js
plugins: [
  {
    resolve: `gatsby-transformer-remark`,
    options: {
      plugins: [
        `gatsby-remark-copy-linked-files`,
      ]
    }
  }
]

Then in your Markdown files, simply link to the file you desire to reference.

E.g.

---
title: My awesome blog post
---

Hey everyone, I just made a sweet PDF with lots of interesting stuff in
it.

[Download it now](my-awesome-pdf.pdf)

my-awesome-pdf.pdf should be in the same directory as the markdown file. When you build your site, the file will be copied to the public folder and the markdown HTML will be modified to point to it.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.2.0
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.2.0
    1
  • 0.1.0
    0

Package Sidebar

Install

npm i @comsoc/gatsby-mdast-copy-linked-files

Weekly Downloads

1

Version

0.2.0

License

MIT

Last publish

Collaborators

  • brudil