Skip to content

Commit 1af1996

Browse files
committed
feat(unstable): add package
1 parent c431b6e commit 1af1996

File tree

8 files changed

+55
-1
lines changed

8 files changed

+55
-1
lines changed

@mizu/unstable/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
> [!CAUTION]
2+
> Features from this package may be subject to change in future versions. Use at your own risk.

@mizu/unstable/deno.jsonc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"name": "@mizu/unstable",
3+
"version": "0.1.0",
4+
"exports": {
5+
"./noop": "./noop/mod.ts"
6+
}
7+
}

@mizu/unstable/noop/README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# `*noop`
2+
3+
| Version | Phase | Multiple |
4+
| ---------------------------------------------- | -------------- | -------- |
5+
| ![](https://jsr.io/badges/@mizu/unstable/noop) | 10 — `TESTING` | Yes |
6+
7+
This directive does nothing.
8+
9+
```html
10+
<div *noop=""></div>
11+
```

@mizu/unstable/noop/mod.html

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<mizu-directive id="noop" directory="unstable/noop">
2+
<code #name><span class="hljs-keyword">*noop</span></code>
3+
<p #description>
4+
This directive does nothing.
5+
</p>
6+
<code #example *skip>
7+
<div *noop></div>
8+
</code>
9+
</mizu-directive>

@mizu/unstable/noop/mod.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Imports
2+
import { type Directive, Phase } from "@mizu/mizu/core/engine"
3+
export type * from "@mizu/mizu/core/engine"
4+
5+
/** `*_noop` directive. */
6+
export const _noop = {
7+
name: "*noop",
8+
phase: Phase.TESTING,
9+
multiple: true,
10+
} as Directive
11+
12+
/** Default exports. */
13+
export default _noop

@mizu/unstable/noop/mod_test.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<load directives="@mizu/unstable/noop"></load>
2+
3+
<test name="[*noop] does nothing">
4+
<render>
5+
<p *noop>foo</p>
6+
</render>
7+
<expect>
8+
<p>foo</p>
9+
</expect>
10+
</test>

@mizu/unstable/noop/mod_test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
await import("@mizu/mizu/core/testing").then(({ test }) => test(import.meta))

deno.jsonc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,8 @@
8888
"@mizu/skip",
8989
"@mizu/test",
9090
"@mizu/text",
91-
"@mizu/toc"
91+
"@mizu/toc",
92+
"@mizu/unstable"
9293
],
9394
"fmt": {
9495
"semiColons": false,

0 commit comments

Comments
 (0)