Skip to content

Commit

Permalink
docs: update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
brillout committed Mar 8, 2022
1 parent 463004d commit 29f4479
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/guide/features.md
Expand Up @@ -298,10 +298,10 @@ const modules = {
}
```

`import.meta.glob` and `import.meta.globEager` also support importing files as strings, similar to [Importing Asset as String](https://vitejs.dev/guide/assets.html#importing-asset-as-string). Here, we use the [Import Assertions](https://github.com/tc39/proposal-import-assertions#synopsis) syntax to import.
`import.meta.glob` and `import.meta.globEager` also support importing files as strings (similar to [Importing Asset as String](https://vitejs.dev/guide/assets.html#importing-asset-as-string)) with the [Import Reflection](https://github.com/tc39/proposal-import-reflection) syntax:

```js
const modules = import.meta.glob('./dir/*.js', { assert: { type: 'raw' } })
const modules = import.meta.glob('./dir/*.js', { as: 'raw' })
```

The above will be transformed into the following:
Expand Down

0 comments on commit 29f4479

Please sign in to comment.