0.3.3 • Published 1 year ago

@itsmatteomanf/astro-security-txt v0.3.3

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@itsmatteomanf/astro-security-txt

This is an Astro integration that allows you to easily add a security.txt file to your Astro site.

Usage

Prerequisites

You need to be using astro@4.0.0 or higher.

Installation

Install the integration automatically using the Astro CLI:

pnpm astro add @itsmatteomanf/astro-security-txt
npx astro add @itsmatteomanf/astro-security-txt
yarn astro add @itsmatteomanf/astro-security-txt

Or install it manually:

  1. Install the required dependencies
pnpm add @itsmatteomanf/astro-security-txt
npm install @itsmatteomanf/astro-security-txt
yarn add @itsmatteomanf/astro-security-txt
  1. Add the integration to your astro config
+import securityTxt from "@itsmatteomanf/astro-security-txt";

export default defineConfig({
  integrations: [
+    securityTxt({
+      contact: 'mailto:example@example.com'
+    }),
  ],
});

Configuration

The configuration opbject, with its defaults, is here:

const options = {
  contact: undefined,
  expires: new Date(Date.now() + 1000 * 60 * 60 * 24 * 365),
  encryption: undefined,
  acknowledgements: undefined,
  preferredLanguages: undefined,
  canonical: undefined,
  policy: undefined,
  hiring: undefined,
  csaf: undefined,
};

The only required option is contact, which must be a string or an array of strings.

All other options are optional, or a string or an array of strings.

It follows the specs at securitytxt.org.

Licensing

MIT Licensed. Made with ❤️ by Matteo Manfredi.

0.3.3

1 year ago

0.3.2

1 year ago

0.3.1

1 year ago

0.3.0

1 year ago

0.2.1

1 year ago

0.2.0

1 year ago

0.1.0

1 year ago