Skip to content

Commit 027350e

Browse files
Merge pull request #122 from zenn-dev/canary
release v0.3.0
2 parents 7e4bf89 + 4f8406a commit 027350e

File tree

7 files changed

+1165
-364
lines changed

7 files changed

+1165
-364
lines changed

.vscode/settings.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
{
33
"editor.formatOnSave": true,
44
"editor.codeActionsOnSave": {
5-
"source.fixAll.eslint": true
5+
"source.fixAll.eslint": "explicit"
66
},
77
"files.exclude": {
88
"out": false // set this to true to hide the "out" folder with the compiled JS files

examples/example_user1/articles/.keep

Whitespace-only changes.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,204 @@
1+
---
2+
title: "Code Fence"
3+
emoji: 👩‍💻
4+
type: "tech" # or "idea"
5+
topics:
6+
- React
7+
- Rust
8+
published: false
9+
---
10+
11+
```"><img/onerror="alert(location)"src=.>
12+
any
13+
```
14+
15+
```tf
16+
terraform {
17+
required_providers {
18+
aws = {
19+
source = "hashicorp/aws"
20+
version = "~> 1.0.4"
21+
}
22+
}
23+
}
24+
25+
variable "aws_region" {}
26+
27+
variable "base_cidr_block" {
28+
description = "A /16 CIDR range definition, such as 10.1.0.0/16, that the VPC will use"
29+
default = "10.1.0.0/16"
30+
}
31+
32+
variable "availability_zones" {
33+
description = "A list of availability zones in which to create subnets"
34+
type = list(string)
35+
}
36+
37+
provider "aws" {
38+
region = var.aws_region
39+
}
40+
41+
resource "aws_vpc" "main" {
42+
# Referencing the base_cidr_block variable allows the network address
43+
# to be changed without modifying the configuration.
44+
cidr_block = var.base_cidr_block
45+
}
46+
47+
resource "aws_subnet" "az" {
48+
# Create one subnet for each given availability zone.
49+
count = length(var.availability_zones)
50+
51+
# For each subnet, use one of the specified availability zones.
52+
availability_zone = var.availability_zones[count.index]
53+
54+
# By referencing the aws_vpc.main object, Terraform knows that the subnet
55+
# must be created only after the VPC is created.
56+
vpc_id = aws_vpc.main.id
57+
58+
# Built-in functions and operators can be used for simple transformations of
59+
# values, such as computing a subnet address. Here we create a /20 prefix for
60+
# each subnet, using consecutive addresses for each availability zone,
61+
# such as 10.1.16.0/20 .
62+
cidr_block = cidrsubnet(aws_vpc.main.cidr_block, 4, count.index+1)
63+
}
64+
```
65+
66+
ref: https://github.com/zenn-dev/zenn-community/issues/357
67+
68+
<!-- should ignore foo -->
69+
70+
```js foo
71+
const foo = function (bar) {
72+
return bar++;
73+
};
74+
```
75+
76+
```diff jsx:src/App.js
77+
function App() {
78+
const [count, setCount] = useState(0);
79+
80+
return (
81+
<div className="App">
82+
- 👆 should not be empty here
83+
+ <h1>Counter App 🧮</h1>
84+
+ <button>
85+
+ +
86+
+ </button>
87+
+ <h3>{count} times clicked!🖱</h3>
88+
</div>
89+
);
90+
}
91+
92+
export default App;
93+
```
94+
95+
```vue:index.vue
96+
<template>
97+
<div class="todo">
98+
<h1>TODO APP</h1>
99+
</div>
100+
</template>
101+
102+
<script lang="ts">
103+
import { defineComponent } from 'vue';
104+
105+
export default defineComponent({
106+
name: 'Todo',
107+
});
108+
</script>
109+
```
110+
111+
```Dockerfile:Dockerfile
112+
FROM ubuntu
113+
ENV name value # comment
114+
ENV name=value
115+
CMD ["echo", "$name"]
116+
```
117+
118+
```bash:foo.fish
119+
bind -M $mode \cq foo
120+
```
121+
122+
```diff
123+
@@ -4,6 +4,5 @@
124+
- let foo = bar.baz([1, 2, 3]);
125+
- foo = foo + 1;
126+
+ const foo = bar.baz([1, 2, 3]) + 1;
127+
console.log(`foo: ${foo}`);
128+
```
129+
130+
```diff
131+
@@ -4,6 +4,5 @@
132+
- let foo = bar.baz([1, 2, 3]);
133+
- foo = foo + 1;
134+
+ const foo = bar.baz([1, 2, 3]) + 1;
135+
console.log(`foo: ${foo}`);
136+
```
137+
138+
```js diff:diff with looooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooong lang
139+
@@ -4,6 +4,5 @@
140+
- let foo = bar.baz([1, 2, 3]);
141+
- foo = foo + 1;
142+
+ const foo = bar.baz([1, 2, 3]) + 1;
143+
console.log(`foo: ${foo}`);
144+
```
145+
146+
```js diff:diff with lang
147+
@@ -4,6 +4,5 @@
148+
- let foo = bar.baz([1, 2, 3]);
149+
- foo = foo + 1;
150+
+ const foo = bar.baz([1, 2, 3]) + 1;
151+
console.log(`foo: ${foo}`);
152+
```
153+
154+
```diff js:diff with lang
155+
@@ -4,6 +4,5 @@
156+
- let foo = bar.baz([1, 2, 3]);
157+
- foo = foo + 1;
158+
+ const foo = bar.baz([1, 2, 3]) + 1;
159+
console.log(`foo: ${foo}`);
160+
```
161+
162+
```js:fooBar.js
163+
var foo = function (bar) {
164+
return bar++;
165+
};
166+
167+
console.log(foo(5));
168+
// 👇can scroll horizontally
169+
console.log(aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa);
170+
```
171+
172+
```js:example
173+
var foo = function (bar) {
174+
return bar++;
175+
};
176+
```
177+
178+
```html:<should escape>
179+
var foo = function (bar) {
180+
return bar++;
181+
};
182+
```
183+
184+
```html
185+
<div>a</div>
186+
```
187+
188+
```diff html:html差分
189+
<div>a</div>
190+
- <div>b</div>
191+
+ <div>c</div>
192+
```
193+
194+
```html diff : html差分
195+
<div>a</div>
196+
-
197+
<div>b</div>
198+
+
199+
<div>c</div>
200+
```
201+
202+
```"><img/onerror="alert(location)"src=.>
203+
"><img/onerror="alert(location)"src=.>
204+
```

package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"url": "https://github.com/zenn-dev/zenn-vscode-extension.git"
1111
},
1212
"license": "MIT",
13-
"version": "0.2.0",
13+
"version": "0.3.0",
1414
"pricing": "Free",
1515
"engines": {
1616
"vscode": "^1.72.0"
@@ -225,7 +225,8 @@
225225
"@types/webpack-env": "^1.17.0",
226226
"@typescript-eslint/eslint-plugin": "^5.30.0",
227227
"@typescript-eslint/parser": "^5.30.0",
228-
"@vscode/test-web": "^0.0.26",
228+
"@vscode/test-web": "^0.0.65",
229+
"@vscode/vsce": "^3.2.2",
229230
"assert": "^2.0.0",
230231
"crypto-browserify": "^3.12.0",
231232
"css-loader": "^6.7.1",
@@ -243,7 +244,6 @@
243244
"style-loader": "^3.3.1",
244245
"ts-loader": "^9.3.1",
245246
"typescript": "^4.7.4",
246-
"vsce": "^2.13.0",
247247
"webpack": "^5.73.0",
248248
"webpack-cli": "^4.10.0"
249249
},

0 commit comments

Comments
 (0)