Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misc: Cleanup typescript webpack types #16780

Merged
merged 1 commit into from Nov 25, 2021
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/angular/src/server/utils/filter-out-styling-rules.ts
@@ -1,4 +1,4 @@
import { Configuration, RuleSetRule } from 'webpack';
import type { Configuration, RuleSetRule } from 'webpack';

const isStylingRule = (rule: RuleSetRule) => {
const { test } = rule;
Expand Down
2 changes: 0 additions & 2 deletions app/react/src/typings.d.ts
@@ -1,4 +1,2 @@
declare module '@storybook/semver';
declare module 'global';
// todo check for correct types
declare module 'webpack/lib/RuleSet';
2 changes: 0 additions & 2 deletions app/vue/src/typings.d.ts
@@ -1,5 +1,3 @@
declare module 'global';
// todo check for correct types
declare module 'webpack/lib/RuleSet';

declare module 'vue-loader/lib/plugin';
2 changes: 0 additions & 2 deletions app/vue3/src/typings.d.ts
@@ -1,6 +1,4 @@
declare module 'global';
// todo check for correct types
declare module 'webpack/lib/RuleSet';

declare module 'vue-loader' {
export const VueLoaderPlugin
Expand Down
2 changes: 1 addition & 1 deletion lib/builder-webpack4/src/preview/iframe-webpack.config.ts
@@ -1,7 +1,7 @@
import path from 'path';
import { DefinePlugin, HotModuleReplacementPlugin, ProgressPlugin } from 'webpack';
// @ts-ignore
import { Configuration, RuleSetRule } from '@types/webpack';
import type { Configuration, RuleSetRule } from '@types/webpack';
import HtmlWebpackPlugin from 'html-webpack-plugin';
import CaseSensitivePathsPlugin from 'case-sensitive-paths-webpack-plugin';
import WatchMissingNodeModulesPlugin from 'react-dev-utils/WatchMissingNodeModulesPlugin';
Expand Down
2 changes: 1 addition & 1 deletion lib/core-common/src/utils/es6Transpiler.ts
@@ -1,4 +1,4 @@
import { RuleSetRule } from 'webpack';
import type { RuleSetRule } from 'webpack';
import { getStorybookBabelConfig } from './babel';

const { plugins } = getStorybookBabelConfig();
Expand Down
2 changes: 1 addition & 1 deletion lib/manager-webpack4/src/presets/babel-loader-manager.ts
@@ -1,4 +1,4 @@
import { RuleSetRule } from 'webpack';
import type { RuleSetRule } from 'webpack';
import { getProjectRoot, getStorybookBabelConfig } from '@storybook/core-common';

export const babelLoader = () => {
Expand Down
2 changes: 1 addition & 1 deletion lib/manager-webpack5/src/presets/babel-loader-manager.ts
@@ -1,4 +1,4 @@
import { RuleSetRule } from 'webpack';
import type { RuleSetRule } from 'webpack';
import { getProjectRoot, getStorybookBabelConfig } from '@storybook/core-common';

export const babelLoader = () => {
Expand Down