diff --git a/CHANGELOG.md b/CHANGELOG.md index 9e7911a..43d7b3d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,39 +1,3 @@ -## 0.0.10 - -- Cleanup - -## 0.0.9 - -- Cleanup - -## 0.0.8 - -- Cleanup - -## 0.0.7 - -- Cleanup - -## 0.0.6 - -- Cleanup - -## 0.0.5 - -- Cleanup - -## 0.0.4 - -- Cleanup - -## 0.0.3 - -- Cleanup - -## 0.0.2 - -- Cleanup - ## 0.0.1 - Initial version diff --git a/Documentation/functions/Configuration.configuration.html b/Documentation/functions/Configuration.configuration.html index 393eee8..4653b81 100644 --- a/Documentation/functions/Configuration.configuration.html +++ b/Documentation/functions/Configuration.configuration.html @@ -1 +1 @@ -
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
The right-most parameter is considered {to}. Other parameters are considered an array of {from}.
+The right-most parameter is considered {to}. Other parameters are considered an array of {from}.
Starting from leftmost {from} parameter, resolves {to} to an absolute path.
If {to} isn't already absolute, {from} arguments are prepended in right to left order, until an absolute path is found. If after using all {from} paths still no absolute path is found, @@ -6,4 +6,4 @@ and trailing slashes are removed unless the path gets resolved to the root directory.
Rest
...paths: string[]A sequence of paths or path segments.
if any of the arguments is not a string.
-Generated using TypeDoc
Generated using TypeDoc
Merges multiple objects of type Ts using the provided merge functions and built-in metadata.
-Rest
...Objects: TsGenerated using TypeDoc
Merges multiple objects of type Ts using the provided merge functions and built-in metadata.
+Rest
...Objects: TsGenerated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
| |||
Compress 🗜️ Compress Astro. | Critters 🦔 Inline CSS. |
| |||
Compress 🗜️ Compress Astro. | Critters 🦔 Inline CSS. |
This Astro integration brings Biome tools your Astro +
This Astro integration brings Biome tools your Astro project.
Note
-
AstroBiome
will not lint / format your requests, only your statically +
BiomeAstro
will not lint / format your requests, only your statically generated build and pre-rendered routes.
There are two ways to add integrations to your project. Let's try the most @@ -16,24 +16,24 @@
astro.config.*
file to apply this integrationTo install AstroBiome
, run the following from your project directory and
+
To install BiomeAstro
, run the following from your project directory and
follow the prompts:
Using NPM:
-npx astro add astro-biome
+npx astro add @playform/biome-astro
Using Yarn:
-yarn astro add astro-biome
+yarn astro add @playform/biome-astro
Using PNPM:
-pnpx astro add astro-biome
+pnpx astro add @playform/biome-astro
-Install dependencies manually
First, install the AstroBiome
integration like so:
-npm install -D -E astro-biome
+Install dependencies manually
First, install the BiomeAstro
integration like so:
+npm install -D -E @playform/biome-astro
Then, apply this integration to your astro.config.*
file using the
integrations
property:
astro.config.ts
-import Biome from "astro-biome";
export default { integrations: [Biome()] };
+import Biome from "@playform/biome-astro";
export default { integrations: [Biome()] };
Getting started
The utility will now lint and format with Biome all of your JavaScript
and TypeScript files, including CommonJS modules in the Astro outDir
folder.
@@ -43,7 +43,7 @@
or disable them entirely:
astro.config.ts
-import Biome from "astro-biome";
export default {
integrations: [
Biome({
Biome: false,
}),
],
};
+import Biome from "@playform/biome-astro";
export default {
integrations: [
Biome({
Biome: false,
}),
],
};
Note
@@ -58,25 +58,25 @@
Add Multiple Paths
You can add multiple paths to validate / format by specifying an array as the
Path
variable.
astro.config.ts
-import Biome from "astro-biome";
export default {
integrations: [
Biome({
Path: ["./Target", "./Build"],
}),
],
};
+import Biome from "@playform/biome-astro";
export default {
integrations: [
Biome({
Path: ["./Target", "./Build"],
}),
],
};
Input-Output Mapping
You can also provide a map of paths for different input output directories:
astro.config.ts
-import Biome from "astro-biome";
export default {
integrations: [
Biome({
Path: new Map([["./Source", "./Target"]]),
}),
],
};
+import Biome from "@playform/biome-astro";
export default {
integrations: [
Biome({
Path: new Map([["./Source", "./Target"]]),
}),
],
};
Or an array of the two:
astro.config.ts
-import Biome from "astro-biome";
export default {
integrations: [
Biome({
Path: [
// Format Target
"./Target",
// Format Target one more time into a different directory
new Map([["./Target", "./TargetInline"]]),
],
}),
],
};
+import Biome from "@playform/biome-astro";
export default {
integrations: [
Biome({
Path: [
// Format Target
"./Target",
// Format Target one more time into a different directory
new Map([["./Target", "./TargetInline"]]),
],
}),
],
};
File Filtering
You can provide a filter to exclude files from formatting. A filter can be an
array of regexes or a single match. You can use functions, as well to match on
file names:
astro.config.ts
-import Biome from "astro-biome";
export default {
integrations: [
Biome({
Exclude: [
"Firebase.ts",
(File: string) => File === "./Source/Library/File.ts",
],
}),
],
};
+import Biome from "@playform/biome-astro";
export default {
integrations: [
Biome({
Exclude: [
"Firebase.ts",
(File: string) => File === "./Source/Library/File.ts",
],
}),
],
};
Controlling Logging
Set Logger
to 0
if you do not want to see debug messages. Default is 2
:
astro.config.ts
-import Biome from "astro-biome";
export default {
integrations: [
Biome({
Logger: 0,
}),
],
};
+import Biome from "@playform/biome-astro";
export default {
integrations: [
Biome({
Logger: 0,
}),
],
};
Changelog
See CHANGELOG.md for a history of changes to this integration.
-
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Optional
ActionAction pipe configuration.
-Optional
BiomeOptional
CacheConfiguration for the target cache.
+Optional
BiomeOptional
CacheConfiguration for the target cache.
{ Search: "./", Folder: "./Cache" }
-Optional
ExcludeCriteria for excluding files.
-Optional
FileFile patterns to be matched.
-Optional
LoggerDebugging level.
+Optional
ExcludeCriteria for excluding files.
+Optional
FileFile patterns to be matched.
+Optional
LoggerDebugging level.
2
-Optional
PathConfiguration for the target path(s).
+Optional
PathConfiguration for the target path(s).
"./Target"
-Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Asynchronously reads the entire contents of a file.
+- Preparing search index...
- The search index is not available
@playform/biome-astro - v0.0.1Function readFile
Asynchronously reads the entire contents of a file.
If no encoding is specified (using
options.encoding
), the data is returned as aBuffer
object. Otherwise, the data will be a string.If
@@ -20,14 +20,14 @@options
is a string, then it specifies the encoding.Parameters
filename or
FileHandle
Optional
options: null | {encoding?: null;
flag?: OpenMode;
} & Abortable
Returns Promise<Buffer>
Fulfills with the contents of the file.
Since
v10.0.0
-Asynchronously reads the entire contents of a file.
+Asynchronously reads the entire contents of a file.
Parameters
A path to a file. If a URL is provided, it must use the
file:
protocol. If aFileHandle
is provided, the underlying file will not be closed automatically.encoding: BufferEncoding;
flag?: OpenMode | undefined;
} & Abortable | BufferEncoding
An object that may contain an optional flag. If a flag is not provided, it defaults to
-'r'
.Returns Promise<string>
Asynchronously reads the entire contents of a file.
+Returns Promise<string>
Asynchronously reads the entire contents of a file.
Parameters
A path to a file. If a URL is provided, it must use the
file:
protocol. If aFileHandle
is provided, the underlying file will not be closed automatically.Optional
options: null | BufferEncoding | ObjectEncodingOptions & Abortable & {flag?: OpenMode | undefined;
}
An object that may contain an optional flag. If a flag is not provided, it defaults to
-'r'
.Returns Promise<string | Buffer>
Settings
Member Visibility
Theme