It appears you have a well-structured Git repository with various files, including SVG icons and HTML documents. Here's a brief overview:
This commit is contained in:
59
backend/node_modules/read-pkg/index.d.ts
generated
vendored
Normal file
59
backend/node_modules/read-pkg/index.d.ts
generated
vendored
Normal file
@@ -0,0 +1,59 @@
|
||||
import * as typeFest from 'type-fest';
|
||||
import * as normalize from 'normalize-package-data';
|
||||
|
||||
export interface Options {
|
||||
/**
|
||||
Current working directory.
|
||||
|
||||
@default process.cwd()
|
||||
*/
|
||||
readonly cwd?: string;
|
||||
|
||||
/**
|
||||
[Normalize](https://github.com/npm/normalize-package-data#what-normalization-currently-entails) the package data.
|
||||
|
||||
@default true
|
||||
*/
|
||||
readonly normalize?: boolean;
|
||||
}
|
||||
|
||||
export interface NormalizeOptions extends Options {
|
||||
readonly normalize?: true;
|
||||
}
|
||||
|
||||
export type NormalizedPackageJson = PackageJson & normalize.Package;
|
||||
export type PackageJson = typeFest.PackageJson;
|
||||
|
||||
/**
|
||||
@returns The parsed JSON.
|
||||
|
||||
@example
|
||||
```
|
||||
import {readPackageAsync} from 'read-pkg';
|
||||
|
||||
console.log(await readPackageAsync());
|
||||
//=> {name: 'read-pkg', …}
|
||||
|
||||
console.log(await readPackageAsync({cwd: 'some-other-directory'});
|
||||
//=> {name: 'unicorn', …}
|
||||
```
|
||||
*/
|
||||
export function readPackageAsync(options?: NormalizeOptions): Promise<NormalizedPackageJson>;
|
||||
export function readPackageAsync(options: Options): Promise<PackageJson>;
|
||||
|
||||
/**
|
||||
@returns The parsed JSON.
|
||||
|
||||
@example
|
||||
```
|
||||
import {readPackageSync} from 'read-pkg';
|
||||
|
||||
console.log(readPackageSync());
|
||||
//=> {name: 'read-pkg', …}
|
||||
|
||||
console.log(readPackageSync({cwd: 'some-other-directory'});
|
||||
//=> {name: 'unicorn', …}
|
||||
```
|
||||
*/
|
||||
export function readPackageSync(options?: NormalizeOptions): NormalizedPackageJson;
|
||||
export function readPackageSync(options: Options): PackageJson;
|
26
backend/node_modules/read-pkg/index.js
generated
vendored
Normal file
26
backend/node_modules/read-pkg/index.js
generated
vendored
Normal file
@@ -0,0 +1,26 @@
|
||||
import fs, {promises as fsAsync} from 'fs';
|
||||
import path from 'path';
|
||||
import parseJson from 'parse-json';
|
||||
import normalizePackageData from 'normalize-package-data';
|
||||
|
||||
export async function readPackageAsync({cwd = process.cwd(), normalize = true} = {}) {
|
||||
const filePath = path.resolve(cwd, 'package.json');
|
||||
const json = parseJson(await fsAsync.readFile(filePath, 'utf8'));
|
||||
|
||||
if (normalize) {
|
||||
normalizePackageData(json);
|
||||
}
|
||||
|
||||
return json;
|
||||
}
|
||||
|
||||
export function readPackageSync({cwd = process.cwd(), normalize = true} = {}) {
|
||||
const filePath = path.resolve(cwd, 'package.json');
|
||||
const json = parseJson(fs.readFileSync(filePath, 'utf8'));
|
||||
|
||||
if (normalize) {
|
||||
normalizePackageData(json);
|
||||
}
|
||||
|
||||
return json;
|
||||
}
|
9
backend/node_modules/read-pkg/license
generated
vendored
Normal file
9
backend/node_modules/read-pkg/license
generated
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (https://sindresorhus.com)
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
52
backend/node_modules/read-pkg/package.json
generated
vendored
Normal file
52
backend/node_modules/read-pkg/package.json
generated
vendored
Normal file
@@ -0,0 +1,52 @@
|
||||
{
|
||||
"name": "read-pkg",
|
||||
"version": "6.0.0",
|
||||
"description": "Read a package.json file",
|
||||
"license": "MIT",
|
||||
"repository": "sindresorhus/read-pkg",
|
||||
"funding": "https://github.com/sponsors/sindresorhus",
|
||||
"author": {
|
||||
"name": "Sindre Sorhus",
|
||||
"email": "sindresorhus@gmail.com",
|
||||
"url": "https://sindresorhus.com"
|
||||
},
|
||||
"type": "module",
|
||||
"exports": "./index.js",
|
||||
"engines": {
|
||||
"node": ">=12"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "xo && ava && tsd"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"keywords": [
|
||||
"json",
|
||||
"read",
|
||||
"parse",
|
||||
"file",
|
||||
"fs",
|
||||
"graceful",
|
||||
"load",
|
||||
"package",
|
||||
"normalize"
|
||||
],
|
||||
"dependencies": {
|
||||
"@types/normalize-package-data": "^2.4.0",
|
||||
"normalize-package-data": "^3.0.2",
|
||||
"parse-json": "^5.2.0",
|
||||
"type-fest": "^1.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"ava": "^3.15.0",
|
||||
"tsd": "^0.14.0",
|
||||
"xo": "^0.38.2"
|
||||
},
|
||||
"xo": {
|
||||
"ignores": [
|
||||
"test/test.js"
|
||||
]
|
||||
}
|
||||
}
|
72
backend/node_modules/read-pkg/readme.md
generated
vendored
Normal file
72
backend/node_modules/read-pkg/readme.md
generated
vendored
Normal file
@@ -0,0 +1,72 @@
|
||||
# read-pkg
|
||||
|
||||
> Read a package.json file
|
||||
|
||||
## Why
|
||||
|
||||
- [Throws more helpful JSON errors](https://github.com/sindresorhus/parse-json)
|
||||
- [Normalizes the data](https://github.com/npm/normalize-package-data#what-normalization-currently-entails)
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install read-pkg
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
import {readPackageAsync} from 'read-pkg';
|
||||
|
||||
console.log(await readPkg());
|
||||
//=> {name: 'read-pkg', …}
|
||||
|
||||
console.log(await readPkg({cwd: 'some-other-directory'}));
|
||||
//=> {name: 'unicorn', …}
|
||||
```
|
||||
|
||||
## API
|
||||
|
||||
### readPackageAsync(options?)
|
||||
|
||||
Returns a `Promise<object>` with the parsed JSON.
|
||||
|
||||
### readPackageSync(options?)
|
||||
|
||||
Returns the parsed JSON.
|
||||
|
||||
#### options
|
||||
|
||||
Type: `object`
|
||||
|
||||
##### cwd
|
||||
|
||||
Type: `string`\
|
||||
Default: `process.cwd()`
|
||||
|
||||
Current working directory.
|
||||
|
||||
##### normalize
|
||||
|
||||
Type: `boolean`\
|
||||
Default: `true`
|
||||
|
||||
[Normalize](https://github.com/npm/normalize-package-data#what-normalization-currently-entails) the package data.
|
||||
|
||||
## Related
|
||||
|
||||
- [read-pkg-up](https://github.com/sindresorhus/read-pkg-up) - Read the closest package.json file
|
||||
- [write-pkg](https://github.com/sindresorhus/write-pkg) - Write a `package.json` file
|
||||
- [load-json-file](https://github.com/sindresorhus/load-json-file) - Read and parse a JSON file
|
||||
|
||||
---
|
||||
|
||||
<div align="center">
|
||||
<b>
|
||||
<a href="https://tidelift.com/subscription/pkg/npm-read-pkg?utm_source=npm-read-pkg&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a>
|
||||
</b>
|
||||
<br>
|
||||
<sub>
|
||||
Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.
|
||||
</sub>
|
||||
</div>
|
Reference in New Issue
Block a user