Skip to content

fix: default value of the static option is static #2897

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

Merged
merged 4 commits into from
Dec 4, 2020
Merged
Changes from 1 commit
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: 2 additions & 1 deletion lib/utils/normalizeOptions.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
'use strict';

const path = require('path');
const isAbsoluteUrl = require('is-absolute-url');
const getCompilerConfigArray = require('./getCompilerConfigArray');

Expand All @@ -14,7 +15,7 @@ function normalizeOptions(compiler, options) {
: {};

const defaultOptionsForStatic = {
directory: process.cwd(),
directory: path.resolve(process.cwd(), 'static'),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't use check directory is exist to allow ability adding static dynamically and working with it without problems

staticOptions: {},
publicPath: ['/'],
serveIndex: { icons: true },
Expand Down