Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

about rollup-plugin-html #2431

Unanswered
alemscoder asked this question in General
Discussion options

Greetings, is there any way to configure the plugin so that the processing of a css linked by the <link> tag is done by PostCSS? Or some plugin configuration that allows me to manage the resources of a css, minify, etc. I've tried doing it but it seems like the css handling is always done by the rollup-plugin-html. Thanks in advance and sorry if the question is dumb, i'm a newbie :)

<!DOCTYPE html>
<html>
<head>
	<title>Test</title>
	<link rel="stylesheet" type="text/css" href="./src/style.css">
	<script type="module" src="./src/index.js"></script>
</head>
<body>
	<h1>Hello world!</h1>
	<img src="./res/images/1.jpg">
	<audio src="./res/audio/t-rex-roar.mp3" controls></audio>
	<video src="./res/video/flower.mp4" width="250" height="200" controls></video>
</body>
</html>
body {
	background-image: url("../res/images/2.jpg");
}
import { nodeResolve } from '@rollup/plugin-node-resolve';
import { rollupPluginHTML as html } from '@web/rollup-plugin-html';
export default {
 input: 'index.html',
 output: { dir: 'dist' },
 plugins: [
 nodeResolve(),
 html()
 ]
}
You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /