
Research
/Security News
Contagious Interview Campaign Escalates With 67 Malicious npm Packages and New Malware Loader
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.
vuepress-plugin-ipfs
Advanced tools
Convert a VuePress 1.x bundle into relative paths making it suitable for hosting on IPFS.
npm i -D vuepress-plugin-ipfs
Add to config.js
or theme/index.js
module.exports = {
plugins: [
['vuepress-plugin-ipfs'],
]
}
Once included this this plugin will post process all generated pages and CSS files to use relative asset paths during a production build.
Sites hosted on IPFS will be accessed via a variable depth so it is important to use relative paths for assets wherever possible, however there are certain scenarios where this is not viable due to components being included on multiple pages (such as headers/footers) or when asset paths are programmatically included.
If your site is accessed via an IPFS gateway the base
path will be computed to include the current IPFS gateway and CID. For example, https://gateway.ipfs.io/ipfs/<CID>/
, then base
will be configured to "/ipfs/<CID>/"
. The same goes for any IPNS gateway paths.
Therefore it is best to use this built in helper method to wrap asset paths. $withBase
(injected onto Vue’s prototype) to generate the correct path when accessed via the root domain or IPFS gateway:
<img :src="$withBase('/foo.png')" alt="foo">
Tip: You can use the above syntax in theme components and Markdown files.
💡If you have a base
key set in .vuepress/config.js
or theme/index.js
you will need to remove it in order for this plugin to work correctly.
FAQs
Host a VuePress project on IPFS
We found that vuepress-plugin-ipfs demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
/Security News
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.
Security News
Meet Socket at Black Hat & DEF CON 2025 for 1:1s, insider security talks at Allegiant Stadium, and a private dinner with top minds in software supply chain security.
Security News
CAI is a new open source AI framework that automates penetration testing tasks like scanning and exploitation up to 3,600× faster than humans.