Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions examples/module-federation/mf-host/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"compilerOptions": {
"target": "ES2020",
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"noEmit": true,
Expand Down
3 changes: 1 addition & 2 deletions examples/module-federation/mf-remote/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"compilerOptions": {
"target": "ES2020",
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"noEmit": true,
Expand Down
3 changes: 1 addition & 2 deletions examples/vue-component-bundle/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
3 changes: 1 addition & 2 deletions examples/vue-component-bundleless/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
7 changes: 3 additions & 4 deletions packages/core/rslib.config.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import fs from 'node:fs';
import path from 'node:path';
import type { RsbuildPlugin } from '@rsbuild/core';
import { pluginPublint } from 'rsbuild-plugin-publint';
import { defineConfig, rspack } from 'rslib';
import { defineConfig, type rsbuild, rspack } from 'rslib';

const pluginFixDtsTypes: RsbuildPlugin = {
const pluginFixDtsTypes: rsbuild.RsbuildPlugin = {
name: 'fix-dts-types',
setup(api) {
api.onAfterBuild(() => {
Expand All @@ -29,7 +28,7 @@ export default defineConfig({
lib: [
{
format: 'esm',
syntax: ['node 16'],
syntax: ['node 18.12.0'],
dts: {
bundle: false,
distPath: './dist-types',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["ES2021"],
"lib": ["ES2022"],
"module": "ESNext",
"noEmit": true,
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["ES2021"],
"lib": ["ES2022"],
"module": "ESNext",
"noEmit": true,
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2021"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"strict": true,
Expand Down
3 changes: 1 addition & 2 deletions packages/create-rslib/fragments/base/vue-ts/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
7 changes: 6 additions & 1 deletion packages/create-rslib/rslib.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@ import { defineConfig } from 'rslib';
const { execSync } = require('node:child_process');

export default defineConfig({
lib: [{ format: 'esm' }],
lib: [
{
format: 'esm',
syntax: ['node 18.12.0'],
},
],
plugins: [
pluginPublint(),
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["ES2021"],
"lib": ["ES2022"],
"module": "ESNext",
"noEmit": true,
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["ES2021"],
"lib": ["ES2022"],
"module": "ESNext",
"noEmit": true,
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["ES2021"],
"lib": ["ES2022"],
"module": "ESNext",
"noEmit": true,
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["ES2021"],
"lib": ["ES2022"],
"module": "ESNext",
"noEmit": true,
"strict": true,
Expand Down
2 changes: 1 addition & 1 deletion packages/create-rslib/template-[react]-[]-ts/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2021"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2021"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2021"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"strict": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2021"],
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"strict": true,
Expand Down
3 changes: 1 addition & 2 deletions packages/create-rslib/template-[vue]-[]-ts/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"compilerOptions": {
"lib": ["DOM", "ES2020"],
"lib": ["DOM", "ES2022"],
"jsx": "preserve",
"target": "ES2020",
"skipLibCheck": true,
"jsxImportSource": "vue",
"useDefineForClassFields": true,
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-dts/rslib.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default defineConfig({
{
format: 'esm',
bundle: false,
syntax: ['node 16'],
syntax: ['node 18.12.0'],
dts: {
bundle: false,
},
Expand Down
4 changes: 2 additions & 2 deletions scripts/tsconfig/base.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"compilerOptions": {
"exactOptionalPropertyTypes": false,
"target": "ES2021",
"target": "ES2022",
"lib": ["DOM", "ESNext"],
"allowJs": false,
"checkJs": false,
"module": "ES2020",
"module": "ES2022",
"strict": true,
"isolatedModules": true,
"esModuleInterop": true,
Expand Down
4 changes: 2 additions & 2 deletions tests/e2e/react-component/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"compilerOptions": {
"target": "ES2020",
"lib": ["DOM", "ES2020"],
"target": "ES2022",
"lib": ["DOM", "ES2022"],
"module": "ESNext",
"jsx": "react-jsx",
"strict": true,
Expand Down
Loading