We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
use file-loader but doesn't create the file to output directory when import file in _Document.jsx
Steps to reproduce the behavior, please provide code snippets or a repository:
git clone https://github.com/iamcco/test-file-loader.git cd test-file-loader yarn build
next.config.js
const withSass = require('@zeit/next-sass') module.exports = withSass({ pageExtensions: ['jsx'], webpack (config) { const { module = {} } = config return { ...config, module: { ...module, rules: [ ...(module.rules || []), { test: /\.(png|woff|woff2|eot|ttf|gif|jpg|ico|svg)$/, loader: 'file-loader', options: { name: '[name]_[hash].[ext]', publicPath: `/_next/static/files`, outputPath: 'static/files' } } ] } } } })
the favicon_1195c05fc68d40d09ebbf24865a55b91.ico files should create at .next/static/ but it create at .next/server/static/
favicon_1195c05fc68d40d09ebbf24865a55b91.ico
.next/static/
.next/server/static/
the favicon_1195c05fc68d40d09ebbf24865a55b91.ico files should create at .next/static/
The text was updated successfully, but these errors were encountered:
_document is just for creating the html structure. Use _app.js for app logic.
Sorry, something went wrong.
@timneutkens if i move to _app,the file will be create twice
.next/server/static/files .next/static/files
what's the difference
No branches or pull requests
Bug report
Describe the bug
use file-loader but doesn't create the file to output directory when import file in _Document.jsx
To Reproduce
Steps to reproduce the behavior, please provide code snippets or a repository:
git clone https://github.com/iamcco/test-file-loader.git cd test-file-loader yarn build
next.config.js
the
favicon_1195c05fc68d40d09ebbf24865a55b91.ico
files should create at.next/static/
but it create at.next/server/static/
Expected behavior
the
favicon_1195c05fc68d40d09ebbf24865a55b91.ico
files should create at.next/static/
Screenshots
System information
The text was updated successfully, but these errors were encountered: