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

fix(web): Added missing type data for "module.hot" calls #1500

Merged
merged 1 commit into from
Jul 25, 2024

Conversation

lslezak
Copy link
Contributor

@lslezak lslezak commented Jul 25, 2024

Problem

  • RPM build fails with this error:
    ERROR in /home/abuild/rpmbuild/BUILD/agama/src/context/installer.jsx
    ./src/context/installer.jsx 93:15-18
    [tsl] ERROR in /home/abuild/rpmbuild/BUILD/agama/src/context/installer.jsx(93,16)
        TS2339: Property 'hot' does not exist on type 'NodeModule'.
    
  • It fails because the module.hot is not known

Solution

  • Explicitly load the types from the @types/webpack-env package
  • Suggested solution found here

Testing

  • Tested manually, the package now builds with osc build locally

@lslezak lslezak merged commit 87b5100 into master Jul 25, 2024
2 checks passed
@lslezak lslezak deleted the missing_types branch July 25, 2024 08:19
@dgdavid
Copy link
Contributor

dgdavid commented Jul 25, 2024

JFTR, related to 804aa4d and 5f484e1

Sorry for not testing the NODE_ENV=production npm run build command once again after the second commit linked above.

@imobachgs imobachgs mentioned this pull request Sep 20, 2024
imobachgs added a commit that referenced this pull request Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants