Skip to content

Conversation

@inottn
Copy link
Collaborator

@inottn inottn commented Nov 28, 2024

Summary

close #8539

module.generator.outputPath is used to specify the output folder for generated assets. While filename can achieve a similar result, it also modifies the associated URL. For example:

generator: {
  // put emitted files under `assets/*.png`
  // runtime request from `https://xxx/cdn/assets/*.png`
  filename: 'assets/[hash][ext][query]',
  publicPath: 'https://xxx/cdn/'
}

generator: {
  // put emitted files under `assets/*.png`
  // runtime request from `https://xxx/cdn/*.png`
  filename: '[hash][ext][query]',
  outputPath: 'assets'
  publicPath: 'https://xxx/cdn/'
}

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@github-actions github-actions bot added the release: feature release: feature related release(mr only) label Nov 28, 2024
@netlify
Copy link

netlify bot commented Nov 28, 2024

Deploy Preview for rspack ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 33f5ca1
🔍 Latest deploy log https://app.netlify.com/sites/rspack/deploys/675533dda51f3600085d397b
😎 Deploy Preview https://deploy-preview-8554--rspack.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@codspeed-hq
Copy link

codspeed-hq bot commented Nov 28, 2024

CodSpeed Performance Report

Merging #8554 will not alter performance

Comparing inottn:feat/generator-outputPath (33f5ca1) with main (8646ecf)

Summary

✅ 1 untouched benchmarks

@inottn inottn force-pushed the feat/generator-outputPath branch from 4a0942a to 33f5ca1 Compare December 8, 2024 05:51
@LingyuCoder LingyuCoder requested a review from ahabhgk December 17, 2024 03:28
@ahabhgk ahabhgk merged commit 61f0cd2 into web-infra-dev:main Dec 17, 2024
32 checks passed
@inottn inottn deleted the feat/generator-outputPath branch December 17, 2024 04:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release: feature release: feature related release(mr only)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Should apply module.generator.outputPath

2 participants