florian-lefebvre / astro-integration-kit

A package that contains utilities to help you build Astro integrations.

Home Page:https://astro-integration-kit.netlify.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

defineIntegration.options should be optional

jdtjenkins opened this issue · comments

At the moment you have to pass parameters when using an integration created with defineIntegration because options isn't optional.

So we want to be able to do this:

integrations: [
  myIntegration(),
],

but at the moment have to do this:

integrations: [
  myIntegration({}),
],

I think it's solved by #27 ? I'm using it for satori-astro and the options type is just never, showing that you shouldn't pass anything, see https://github.com/florian-lefebvre/satori-astro/blob/main/playground/astro.config.mjs#L7

image

image

Hmmm weird, in the tests it gives an error if they aren't defined 🤔