astro 2.0.17 → 2.0.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -421,7 +421,8 @@ async function updateAstroConfig({
421
421
  let output = await generate(ast);
422
422
  const comment = "// https://astro.build/config";
423
423
  const defaultExport = "export default defineConfig";
424
- output = output.replace(` ${comment}`, "");
424
+ output = output.replace(`
425
+ ${comment}`, "");
425
426
  output = output.replace(`${defaultExport}`, `
426
427
  ${comment}
427
428
  ${defaultExport}`);
@@ -2,8 +2,8 @@ import { SUPPORTED_MARKDOWN_FILE_EXTENSIONS } from "./../constants.js";
2
2
  import { fileURLToPath, pathToFileURL } from "url";
3
3
  import jsxRenderer from "../../jsx/renderer.js";
4
4
  import { createDefaultDevConfig } from "./config.js";
5
- import { loadTSConfig } from "./tsconfig.js";
6
5
  import { AstroTimer } from "./timer.js";
6
+ import { loadTSConfig } from "./tsconfig.js";
7
7
  function createBaseSettings(config) {
8
8
  return {
9
9
  config,
@@ -1,4 +1,4 @@
1
- const ASTRO_VERSION = "2.0.17";
1
+ const ASTRO_VERSION = "2.0.18";
2
2
  const SUPPORTED_MARKDOWN_FILE_EXTENSIONS = [
3
3
  ".markdown",
4
4
  ".mdown",
@@ -31,7 +31,7 @@ async function dev(settings, options) {
31
31
  isRestart: options.isRestart
32
32
  })
33
33
  );
34
- const currentVersion = "2.0.17";
34
+ const currentVersion = "2.0.18";
35
35
  if (currentVersion.includes("-")) {
36
36
  warn(options.logging, null, msg.prerelease({ currentVersion }));
37
37
  }
@@ -47,7 +47,7 @@ function serverStart({
47
47
  base,
48
48
  isRestart = false
49
49
  }) {
50
- const version = "2.0.17";
50
+ const version = "2.0.18";
51
51
  const localPrefix = `${dim("\u2503")} Local `;
52
52
  const networkPrefix = `${dim("\u2503")} Network `;
53
53
  const emptyPrefix = " ".repeat(11);
@@ -233,7 +233,7 @@ function printHelp({
233
233
  message.push(
234
234
  linebreak(),
235
235
  ` ${bgGreen(black(` ${commandName} `))} ${green(
236
- `v${"2.0.17"}`
236
+ `v${"2.0.18"}`
237
237
  )} ${headline}`
238
238
  );
239
239
  }
@@ -1,11 +1,11 @@
1
1
  import { viteID } from "../../util.js";
2
- import { isCSSRequest } from "./util.js";
2
+ import { isBuildableCSSRequest } from "./util.js";
3
3
  import { crawlGraph } from "./vite.js";
4
4
  async function getStylesForURL(filePath, loader, mode) {
5
5
  const importedCssUrls = /* @__PURE__ */ new Set();
6
6
  const importedStylesMap = /* @__PURE__ */ new Map();
7
7
  for await (const importedModule of crawlGraph(loader, viteID(filePath), true)) {
8
- if (isCSSRequest(importedModule.url)) {
8
+ if (isBuildableCSSRequest(importedModule.url)) {
9
9
  let ssrModule;
10
10
  try {
11
11
  ssrModule = importedModule.ssrModule ?? await loader.import(importedModule.url);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "astro",
3
- "version": "2.0.17",
3
+ "version": "2.0.18",
4
4
  "description": "Astro is a modern site builder with web best practices, performance, and DX front-of-mind.",
5
5
  "type": "module",
6
6
  "author": "withastro",
@@ -89,7 +89,7 @@
89
89
  "@astrojs/language-server": "^0.28.3",
90
90
  "@astrojs/markdown-remark": "^2.0.1",
91
91
  "@astrojs/telemetry": "^2.0.1",
92
- "@astrojs/webapi": "^2.0.2",
92
+ "@astrojs/webapi": "^2.0.3",
93
93
  "@babel/core": "^7.18.2",
94
94
  "@babel/generator": "^7.18.2",
95
95
  "@babel/parser": "^7.18.4",
@@ -160,7 +160,7 @@
160
160
  "@types/send": "^0.17.1",
161
161
  "@types/server-destroy": "^1.0.1",
162
162
  "@types/unist": "^2.0.6",
163
- "astro-scripts": "0.0.12",
163
+ "astro-scripts": "0.0.13",
164
164
  "chai": "^4.3.6",
165
165
  "cheerio": "^1.0.0-rc.11",
166
166
  "eol": "^0.9.1",
@@ -187,7 +187,6 @@
187
187
  "build:ci": "pnpm run prebuild && astro-scripts build \"src/**/*.ts\"",
188
188
  "dev": "astro-scripts dev --prebuild \"src/runtime/server/astro-island.ts\" --prebuild \"src/runtime/client/{idle,load,media,only,visible}.ts\" \"src/**/*.ts\"",
189
189
  "postbuild": "astro-scripts copy \"src/**/*.astro\"",
190
- "benchmark": "node test/benchmark/dev.bench.js && node test/benchmark/build.bench.js",
191
190
  "test:unit": "mocha --exit --timeout 30000 ./test/units/**/*.test.js",
192
191
  "test:unit:match": "mocha --exit --timeout 30000 ./test/units/**/*.test.js -g",
193
192
  "test": "pnpm run test:unit && mocha --exit --timeout 20000 --ignore **/lit-element.test.js && mocha --timeout 20000 **/lit-element.test.js",