This commit is contained in:
Elizabeth Craig 2024-03-01 19:31:25 -08:00 коммит произвёл GitHub
Родитель b6d2f42cb8
Коммит feb6217bf3
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
15 изменённых файлов: 73 добавлений и 38 удалений

Просмотреть файл

@ -0,0 +1,32 @@
{
"changes": [
{
"type": "none",
"comment": "Update build setup",
"packageName": "just-scripts-utils",
"email": "elcraig@microsoft.com",
"dependentChangeType": "none"
},
{
"type": "none",
"comment": "Update build setup",
"packageName": "just-scripts",
"email": "elcraig@microsoft.com",
"dependentChangeType": "none"
},
{
"type": "none",
"comment": "Update build setup",
"packageName": "just-task-logger",
"email": "elcraig@microsoft.com",
"dependentChangeType": "none"
},
{
"type": "none",
"comment": "Update build setup",
"packageName": "just-task",
"email": "elcraig@microsoft.com",
"dependentChangeType": "none"
}
]
}

Просмотреть файл

@ -8,10 +8,10 @@ Unlike other build libraries, Just strives to be useful from the beginning. You
> NOTE: even though `just-scripts` interacts with `typescript`, it does not take `typescript` as a dependency. It assumes that the developers will include that in their own projects. This gives `just-scripts` the flexibility of targeting many different versions of individual build tools without imposing a version on the consumers.
These scripts are coded as higher order task functions. Each of these script functions return a task function to be registered as a task in your own `just-task.js` like this:
These scripts are coded as higher order task functions. Each of these script functions return a task function to be registered as a task in your own `just.config.js` like this:
```ts
// just-task.js
// just.config.js
import { tscTask } from 'just-scripts';
task('ts', tscTask());
```
@ -19,7 +19,7 @@ task('ts', tscTask());
Generally, these higher order functions also take an `options` argument to generate a specific task function preconfigured according to the options. For example:
```ts
// just-task.js
// just.config.js
import { tscTask } from 'just-scripts';
task('ts:commonjs', tscTask({ module: 'commonjs' }));
task('ts:esnext', tscTask({ module: 'esnext' }));

Просмотреть файл

@ -7,7 +7,7 @@ sidebar_label: Jest
Jest is one of the most popular testing libraries in the Javascript ecosystem. It is also a preset supported out of the box inside the `just-scripts` library. Similar to the other presets, this task function assumes that you have a `jest.config.js` at the root of the project.
```tsx
// just-task.js
// just.config.js
import { jestTask } from 'just-scripts';
task('test', jestTask());
```
@ -15,7 +15,7 @@ task('test', jestTask());
You can pass in a few options like any another preset tasks in the `just-scripts` library.
```tsx
// just-task.js
// just.config.js
import { jestTask } from 'just-scripts';
const options = {

Просмотреть файл

@ -7,7 +7,7 @@ sidebar_label: TypeScript Lint
TypeScript is a very popular compiler. But as the amount of code grows, developers need a way to keep the code looking consistent. `tslint` is the de facto linter for TS code.
```tsx
// just-task.js
// just.config.js
import { tslintTask } from 'just-scripts';
task('tslint', tslintTask());
```

Просмотреть файл

@ -11,7 +11,7 @@ Given a library with TypeScript source code, it might be desirable to have multi
A list of available options are located at the [TypeScript documentation site](http://www.typescriptlang.org/docs/handbook/compiler-options.html). The options passed into the preset function will be passed in as command line arguments as a string.
```tsx
// just-task.js
// just.config.js
import { tscTask } from 'just-scripts';
task('ts', tscTask());
```
@ -19,7 +19,7 @@ task('ts', tscTask());
For variety, try having two kinds of output at the same time (built in parallel)
```tsx
// just-task.js
// just.config.js
import { parallel } from 'just-task';
import { tscTask } from 'just-scripts';
task('ts:commonjs', tscTask({ module: 'commonjs' }));

Просмотреть файл

@ -4,7 +4,7 @@ title: Controlling Task Flow with Conditionals
sidebar_label: Conditionals
---
Sometimes a `just-task.js` includes tasks that are skipped depending on the arguments that are given. Use a `condition()` function to decide to run a task or to skip it.
Sometimes a `just.config.js` includes tasks that are skipped depending on the arguments that are given. Use a `condition()` function to decide to run a task or to skip it.
## Running tasks in a series

Просмотреть файл

@ -1,2 +1,9 @@
__tests__
*.log
*.tgz
api-extractor.json
CHANGELOG.*
__tests__
etc/
jest.config.js
package-deps.json
tsconfig.json

Просмотреть файл

@ -3,6 +3,5 @@
"compilerOptions": {
"outDir": "lib"
},
"include": ["src"],
"exclude": ["**/__tests__/**"]
"include": ["src"]
}

Просмотреть файл

@ -1,6 +1,9 @@
CHANGELOG.*
*.tgz
__tests__
*.log
package-deps.json
*.tgz
api-extractor.json
CHANGELOG.*
etc/
jest.config.js
package-deps.json
tsconfig.json

Просмотреть файл

@ -1,13 +0,0 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
"mainEntryPointFilePath": "<projectFolder>/lib/index.d.ts",
"docModel": {
"enabled": true
},
"dtsRollup": {
"enabled": true
},
"apiReport": {
"enabled": true
}
}

Просмотреть файл

@ -4,6 +4,5 @@
"outDir": "lib",
"sourceMap": true
},
"include": ["src", "typings/*.d.ts"],
"exclude": ["**/__tests__/**"]
"include": ["src"]
}

Просмотреть файл

@ -1,2 +1,9 @@
__tests__
*.log
*.tgz
api-extractor.json
CHANGELOG.*
__tests__
etc/
jest.config.js
package-deps.json
tsconfig.json

Просмотреть файл

@ -3,6 +3,5 @@
"compilerOptions": {
"outDir": "lib"
},
"include": ["src"],
"exclude": ["**/__tests__/**"]
"include": ["src"]
}

Просмотреть файл

@ -1,6 +1,9 @@
CHANGELOG.*
*.tgz
__tests__
*.log
package-deps.json
*.tgz
api-extractor.json
CHANGELOG.*
etc/
jest.config.js
package-deps.json
tsconfig.json

Просмотреть файл

@ -3,6 +3,5 @@
"compilerOptions": {
"outDir": "lib"
},
"include": ["src", "types"],
"exclude": ["**/__tests__/**"]
"include": ["src"]
}