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

Asset name not properly encoded when using % in file name #13923

Closed
7 tasks done
hichemfantar opened this issue Jul 22, 2023 · 2 comments
Closed
7 tasks done

Asset name not properly encoded when using % in file name #13923

hichemfantar opened this issue Jul 22, 2023 · 2 comments

Comments

@hichemfantar
Copy link

Describe the bug

Accessing an asset file url doesn't work because the filename isn't properly url encoded.

Reproduction

https://essths.ieee.tn/assets/logo-10%-d77c36e3.png

Steps to reproduce

I'm using the reactjs template. I created an image file called logo-10%.png in my src folder.

  • Import file import Logo from "./assets/logo-10%.png";
  • Run build
  • Output file name logo-10%-d77c36e3.png
  • Attempting to access the file from the browser doesn't work.
  • Attempting to access the file using this name works: logo-10%25-d77c36e3.png
  • Notice I changed the % to %25
  • I simply encoded it using an online tool

System Info

System:
    OS: Windows 10 10.0.19044
    CPU: (12) x64 Intel(R) Core(TM) i5-10500H CPU @ 2.50GHz
    Memory: 4.79 GB / 15.78 GB
  Binaries:
    Node: 18.16.1 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.19 - C:\Program Files\nodejs\yarn.CMD
    npm: 9.5.1 - C:\Program Files\nodejs\npm.CMD
    pnpm: 8.6.3 - C:\Program Files\nodejs\pnpm.CMD
  Browsers:
    Edge: Spartan (44.19041.1266.0), Chromium (115.0.1901.183)
    Internet Explorer: 11.0.19041.1566

Used Package Manager

npm

Logs

No response

Validations

@benmccann
Copy link
Collaborator

@hichemfantar could you provide a repository with a project that reproduces this issue? We have so many issues filed that we don't have time to create a new project and follow steps to reproduce each issue. We need to just be able to do a git clone and immediately see the issue.

If you do that I can confirm this issue and get it prioritized. Thanks!

@hichemfantar
Copy link
Author

Closed and created a new issue #15298

@github-actions github-actions bot locked and limited conversation to collaborators Dec 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants