inline-source icon indicating copy to clipboard operation
inline-source copied to clipboard

link prefetch

Open tianyk opened this issue 7 years ago • 0 comments

We have some projects, I can not set the inline attribute.

I set attribute option false, but I have some problems.

<link rel="prefetch" href="/img/next.png">

I don't want resolve the prefetch link. What should I do, thanks.

const { inlineSource } = require('inline-source');

(async () => {
	const html = await inlineSource('<head><link rel="prefetch" href="/img/next.png"></head>', {
		attribute: false,
		compress: false,
		swallowErrors: true,
		rootpath: '.'
	});

	console.log(html);
})().catch(console.error);

tianyk avatar Jan 22 '19 02:01 tianyk