Astro Import Assertions
npm install @astropub/assert
import { assertPlugin } from '@astropub/assert'
export default {
vite: {
plugins: [
assertPlugin()
]
}
}

Configuration
You can pass in special handlers for load
and transform
when imports with assertions are encountered.
import { assertions } from '@astropub/assert'
export default {
vite: {
plugins: [
load(id, assert) {
console.log(assert)
}
]
}
}
`load(id, assertions, )
License
Codecs is a remix of Squoosh!.
Code original to this project is licensed under the CC0-1.0 License.
Code from Squoosh! is licensed under the Apache-2.0 License, Copyright Google Inc.