Skip to content

Commit 711fbec

Browse files
committed
misc
1 parent 1064447 commit 711fbec

File tree

9 files changed

+2277
-10
lines changed

9 files changed

+2277
-10
lines changed

eleventyServerlessTest1/netlify.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,7 @@ status = 200
55
force = true
66
_generated_by_eleventy_serverless = "serverless"
77

8+
[dev]
9+
command = "eleventy --serve"
10+
framework = "#custom"
11+
targetPort = 9_998

webctest2/_components/cat.webc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ let height = getRandomInt(200,600);
1717
</template>
1818

1919

20-
<script>
20+
<script webc:keep>
2121
const meow = new Audio('meow.wav');
2222

2323
document.addEventListener('DOMContentLoaded', () => {

webctest2/_includes/main.liquid

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
<head>
44
<meta charset="utf-8">
55
<title></title>
6-
<script>{{ page.url | webcGetJs }}</script>
76
</head>
87

98
<body>

webctest2/index.webc

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,7 @@
22
layout: main
33
---
44

5-
<h1>Cat Test</h1>
5+
<h1>Cats</h1>
66

77
<cat></cat>
8-
9-
<h2>Another Cat</h2>
10-
11-
<cat></cat>
12-
13-
<h3>Hello</h3>
14-
158
<cat></cat>

webctest_css/.eleventy.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
const pluginWebc = require("@11ty/eleventy-plugin-webc");
2+
3+
module.exports = function(eleventyConfig) {
4+
eleventyConfig.addPlugin(pluginWebc);
5+
};

webctest_css/_components/cat.webc

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<p>
2+
This is a cat.
3+
</p>
4+
5+
<style webc:scoped>
6+
:host {
7+
color: blue;
8+
}
9+
:host:defined {
10+
color: rebeccapurple;
11+
}
12+
13+
p {
14+
color: red;
15+
}
16+
</style>

webctest_css/index.webc

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<html>
2+
<head>
3+
<style @raw="getCss(page.url)" webc:keep></style>
4+
</head>
5+
6+
<body>
7+
8+
Hello World!
9+
10+
<cat></cat>
11+
12+
</body>
13+
</html>

0 commit comments

Comments
 (0)