Initial React project

This commit is contained in:
Johan
2026-03-23 07:49:45 +01:00
parent 8d33465f51
commit e204032b56
1353 changed files with 23853 additions and 50282 deletions

39
node_modules/acorn/README.md generated vendored
View File

@@ -26,24 +26,6 @@ git clone https://github.com/acornjs/acorn.git
cd acorn
npm install
```
## Importing acorn
ESM as well as CommonJS is supported for all 3: `acorn`, `acorn-walk` and `acorn-loose`.
ESM example for `acorn`:
```js
import * as acorn from "acorn"
```
CommonJS example for `acorn`:
```js
let acorn = require("acorn")
```
ESM is preferred, as it allows better editor auto-completions by offering TypeScript support.
For this reason, following examples will use ESM imports.
## Interface
@@ -54,8 +36,8 @@ syntax tree object as specified by the [ESTree
spec](https://github.com/estree/estree).
```javascript
import * as acorn from "acorn"
console.log(acorn.parse("1 + 1", {ecmaVersion: 2020}))
let acorn = require("acorn");
console.log(acorn.parse("1 + 1", {ecmaVersion: 2020}));
```
When encountering a syntax error, the parser will raise a
@@ -79,12 +61,11 @@ required):
implemented through plugins.
- **sourceType**: Indicate the mode the code should be parsed in. Can be
either `"script"`, `"module"` or `"commonjs"`. This influences global strict mode
either `"script"` or `"module"`. This influences global strict mode
and parsing of `import` and `export` declarations.
**NOTE**: If set to `"module"`, then static `import` / `export` syntax
will be valid, even if `ecmaVersion` is less than 6. If set to `"commonjs"`,
it is the same as `"script"` except that the top-level scope behaves like a function.
will be valid, even if `ecmaVersion` is less than 6.
- **onInsertedSemicolon**: If given a callback, that callback will be
called whenever a missing semicolon is inserted by the parser. The
@@ -116,7 +97,7 @@ required):
for `ecmaVersion` 2022 and later, `false` for lower versions.
Setting this option to `true` allows to have top-level `await`
expressions. They are still not allowed in non-`async` functions,
though. Setting this option to `true` is not allowed when `sourceType: "commonjs"`.
though.
- **allowSuperOutsideMethod**: By default, `super` outside a method
raises an error. Set this to `true` to accept such code.
@@ -236,7 +217,7 @@ for (let token of acorn.tokenizer(str)) {
}
// transform code to array of tokens:
var tokens = [...acorn.tokenizer(str)]
var tokens = [...acorn.tokenizer(str)];
```
**tokTypes** holds an object mapping names to the token type objects
@@ -257,10 +238,10 @@ on the extended version of the class. To extend a parser with plugins,
you can use its static `extend` method.
```javascript
var acorn = require("acorn")
var jsx = require("acorn-jsx")
var JSXParser = acorn.Parser.extend(jsx())
JSXParser.parse("foo(<bar/>)", {ecmaVersion: 2020})
var acorn = require("acorn");
var jsx = require("acorn-jsx");
var JSXParser = acorn.Parser.extend(jsx());
JSXParser.parse("foo(<bar/>)", {ecmaVersion: 2020});
```
The `extend` method takes any number of plugin values, and returns a