mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
chore: cleanup imports
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
import Config from 'webpack-chain';
|
||||
import { resolve } from 'path'
|
||||
|
||||
import { additionalCopyRules } from '../../src/helpers/copyRules'
|
||||
import {
|
||||
default as angular,
|
||||
getFileReplacementsFromWorkspaceConfig,
|
||||
applyFileReplacements
|
||||
} from '../../src/configuration/angular';
|
||||
import { init } from '../../src';
|
||||
import { additionalCopyRules } from '../../src/helpers/copyRules'
|
||||
|
||||
import { resolve } from 'path'
|
||||
|
||||
jest.mock(
|
||||
'@ngtools/webpack',
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import Config from 'webpack-chain';
|
||||
import fs from 'fs';
|
||||
|
||||
import base from '../../src/configuration/base';
|
||||
import { init } from '../../src';
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import Config from 'webpack-chain';
|
||||
|
||||
import javascript from '../../src/configuration/javascript';
|
||||
import { init } from '../../src';
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import Config from 'webpack-chain';
|
||||
|
||||
import react from '../../src/configuration/react';
|
||||
import { init } from '../../src';
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import Config from 'webpack-chain';
|
||||
|
||||
import svelte from '../../src/configuration/svelte';
|
||||
import { init } from '../../src';
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import Config from 'webpack-chain';
|
||||
|
||||
import typescript from '../../src/configuration/typescript';
|
||||
import { init } from '../../src';
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import Config from 'webpack-chain';
|
||||
|
||||
import vue from '../../src/configuration/vue';
|
||||
import { init } from '../../src';
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import xmlNsLoader from '../../src/loaders/xml-namespace-loader';
|
||||
import dedent from 'ts-dedent';
|
||||
|
||||
import xmlNsLoader from '../../src/loaders/xml-namespace-loader';
|
||||
|
||||
const CODE_FILE = dedent`
|
||||
<Page xmlns="http://www.nativescript.org/tns.xsd">
|
||||
<StackLayout>
|
||||
|
||||
@@ -6,6 +6,7 @@ import dedent from 'ts-dedent';
|
||||
import webpack from 'webpack';
|
||||
import path from 'path';
|
||||
import fs from 'fs';
|
||||
|
||||
import { parseEnvFlags } from '../cli/parseEnvFlags';
|
||||
|
||||
const defaultConfig = path.resolve(
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { IWebpackEnv } from '@nativescript/webpack';
|
||||
import type { IWebpackEnv } from '@nativescript/webpack';
|
||||
|
||||
const ENV_FLAG_RE = /--env\.(\w+)(?:=(.+))?/;
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import Config from 'webpack-chain';
|
||||
import { resolve, dirname } from 'path';
|
||||
import Config from 'webpack-chain';
|
||||
import { existsSync } from 'fs';
|
||||
import get from 'lodash.get'
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { DefinePlugin, HotModuleReplacementPlugin } from 'webpack';
|
||||
import Config from 'webpack-chain';
|
||||
import { resolve } from 'path';
|
||||
import os from 'os';
|
||||
|
||||
import ForkTsCheckerWebpackPlugin from 'fork-ts-checker-webpack-plugin';
|
||||
import FilterWarningsPlugin from 'webpack-filter-warnings-plugin';
|
||||
@@ -22,7 +23,6 @@ import {
|
||||
getEntryDirPath,
|
||||
getEntryPath,
|
||||
} from '../helpers/platform';
|
||||
import os from 'os';
|
||||
|
||||
export default function (config: Config, env: IWebpackEnv = _env): Config {
|
||||
const entryPath = getEntryPath();
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { getPackageJson, getProjectRootPath } from './project';
|
||||
import path from 'path';
|
||||
|
||||
import { getPackageJson, getProjectRootPath } from './project';
|
||||
|
||||
// todo: memoize
|
||||
/**
|
||||
* Utility to get all dependencies from the project package.json.
|
||||
|
||||
Reference in New Issue
Block a user