Skip to content

Commit 215e83b

Browse files
authored
[markdown] update example CSS/JS and add an example readme (#1970)
Also fix the build
1 parent 6e74c97 commit 215e83b

File tree

4 files changed

+18
-8
lines changed

4 files changed

+18
-8
lines changed

.github/workflows/deploy_pages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
# Build the markdown playground.
2929
- run: dart pub get
3030
working-directory: pkgs/markdown
31-
- run: dart run build_runner build -o example:build --release
31+
- run: dart run build_runner build -o example:build --release --delete-conflicting-outputs --verbose
3232
working-directory: pkgs/markdown
3333

3434
# Create the _site directory.

pkgs/markdown/build.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@
22
targets:
33
$default:
44
builders:
5-
build_web_compilers|dart2js_archive_extractor:
6-
options:
7-
filter_outputs: false
85
build_web_compilers|entrypoint:
96
generate_for:
107
- example/**.dart

pkgs/markdown/example/README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
Commands must be executed from the `/markdown` directory.
2+
3+
Run locally with JavaScript development compiler:
4+
5+
```console
6+
dart run build_runner serve example
7+
```
8+
9+
Build production JS and WebAssembly:
10+
11+
```console
12+
dart run build_runner build -o example:build --release
13+
```

pkgs/markdown/example/index.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
<link rel="stylesheet" href="style.css">
55
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto+Mono|Roboto">
66
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons+Extended">
7-
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.5.1/styles/default.min.css" integrity="sha512-hasIneQUHlh06VNBe7f6ZcHmeRTLIaQWFd43YriJ0UND19bvYRauxthDg8E4eVNPm9bRUhr5JGeqH7FRFXQu5g==" crossorigin="anonymous" referrerpolicy="no-referrer" />
8-
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/github-markdown-css/5.1.0/github-markdown-light.min.css" integrity="sha512-zb2pp+R+czM7GAemdSUQt6jFmr3qCo6ikvBgVU6F5GvwEDR0C2sefFiPEJ9QUpmAKdD5EqDUdNRtbOYnbF/eyQ==" crossorigin="anonymous" referrerpolicy="no-referrer" />
9-
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.5.1/highlight.min.js" integrity="sha512-yUUc0qWm2rhM7X0EFe82LNnv2moqArj5nro/w1bi05A09hRVeIZbN6jlMoyu0+4I/Bu4Ck/85JQIU82T82M28w==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
10-
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.5.1/languages/dart.min.js" integrity="sha512-14QR6tzX5xTNeMJKXzSK+xCquDvtNEr1jM5NlKy/149BBY50Kv70qqxHtzo6zClbtc1gIG7G0CGWXuMgPIMt0g==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
7+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/styles/default.min.css" integrity="sha512-hasIneQUHlh06VNBe7f6ZcHmeRTLIaQWFd43YriJ0UND19bvYRauxthDg8E4eVNPm9bRUhr5JGeqH7FRFXQu5g==" crossorigin="anonymous" referrerpolicy="no-referrer" />
8+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/github-markdown-css/5.8.1/github-markdown-light.min.css" integrity="sha512-X175XRJAO6PHAUi8AA7GP8uUF5Wiv+w9bOi64i02CHKDQBsO1yy0jLSKaUKg/NhRCDYBmOLQCfKaTaXiyZlLrw==" crossorigin="anonymous" referrerpolicy="no-referrer" />
9+
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/highlight.min.js" integrity="sha512-EBLzUL8XLl+va/zAsmXwS7Z2B1F9HUHkZwyS/VKwh3S7T/U0nF4BaU29EP/ZSf6zgiIxYAnKLu6bJ8dqpmX5uw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
10+
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/languages/dart.min.js" integrity="sha512-4NIdIujw2gXoLU7x+versij0q7JzrtjDETxeDaBIb2gM7EctoudrUUtWm+aTx9ODExJTTCLzq06Gjs642x/DwA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
1111
<script defer src="app.dart.js"></script>
1212
<title>Dart Markdown Live Editor</title>
1313
<style>

0 commit comments

Comments
 (0)