From d924fcbeb4cf0b198736a8b6e2eba115cfe0027c Mon Sep 17 00:00:00 2001 From: Nate Moore Date: Tue, 4 May 2021 12:15:13 -0500 Subject: [PATCH] Fix `astro-prism` package (#170) * fix: properly include astro-prism * chore: add changeset * Update `astro-prism` description --- .changeset/twelve-forks-pull.md | 6 ++++++ packages/astro-prism/package.json | 4 ++-- packages/astro/components/Prism.astro | 4 ++-- packages/astro/package.json | 2 +- 4 files changed, 11 insertions(+), 5 deletions(-) create mode 100644 .changeset/twelve-forks-pull.md diff --git a/.changeset/twelve-forks-pull.md b/.changeset/twelve-forks-pull.md new file mode 100644 index 0000000000..a77e5622e5 --- /dev/null +++ b/.changeset/twelve-forks-pull.md @@ -0,0 +1,6 @@ +--- +'astro': patch +'astro-prism': patch +--- + +Fix issue with Prism component missing dependency diff --git a/packages/astro-prism/package.json b/packages/astro-prism/package.json index 47e6b3dead..b18d710d6c 100644 --- a/packages/astro-prism/package.json +++ b/packages/astro-prism/package.json @@ -1,7 +1,7 @@ { "name": "astro-prism", - "version": "1.0.0", - "description": "This is not published at this time.", + "version": "0.0.1", + "description": "IYKYK", "main": "index.mjs", "scripts": { "build": "echo 'build'", diff --git a/packages/astro/components/Prism.astro b/packages/astro/components/Prism.astro index a1d504882a..5207d8bda1 100644 --- a/packages/astro/components/Prism.astro +++ b/packages/astro/components/Prism.astro @@ -1,6 +1,6 @@ --- import Prism from 'prismjs'; -import { addAstro } from '../astro-prism/index.mjs'; +import { addAstro } from 'astro-prism'; import * as loadLanguages from 'prismjs/components/index.js'; export let lang; @@ -39,4 +39,4 @@ let html = Prism.highlight(code, grammar, lang); let className = `language-${lang}`; --- -
{html}
\ No newline at end of file +
{html}
diff --git a/packages/astro/package.json b/packages/astro/package.json index 2da876873f..77d770ea33 100644 --- a/packages/astro/package.json +++ b/packages/astro/package.json @@ -22,7 +22,6 @@ "components", "lib", "runtime", - "astro-prism", "snowpack-plugin.cjs", "astro.mjs" ], @@ -43,6 +42,7 @@ "@vue/server-renderer": "^3.0.10", "acorn": "^7.4.0", "astro-parser": "0.0.9", + "astro-prism": "0.0.1", "autoprefixer": "^10.2.5", "cheerio": "^1.0.0-rc.5", "domhandler": "^4.1.0",