Skip to content

Error: The glob pattern import("./**/*.entry.js*") did not match any files [empty-glob]bug:  #5427

Closed

Description

@benjaminmilcic

Prerequisites

Stencil Version

dont know

Current Behavior

-1

In my Angular Project, when i do ng build, the build is canceled and i got:

▲ [WARNING] The glob pattern import("./**/.entry.js") did not match any files [empty-glob]

node_modules/@stencil/core/internal/client/index.js:3808:2:
  3808 │   `./${bundleId}.entry.js${BUILD.hotModuleReplacement && hmrVers...
       ╵   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

ng serve works well.

Has anyone an idea what that means?

Expected Behavior

i expect that the build do not cancel.

System Info

"npx stencil info" gives me:

 Build: 1708962986
     Stencil: 4.12.4
  TypeScript: 5.3.3
      Rollup: 2.56.3
      Parse5: 7.1.2
      jQuery: 4.0.0-pre
      Terser: 5.27.2

Steps to Reproduce

i do not know

Code Reproduction URL

i do not know

Additional Information

No response

Activity

  1. christian-bromann commented on Mar 3, 2024

    @christian-bromann
    Member

    @benjaminmilcic thanks for raising the issue.

    It would be great if you could provide a bit more information to help us reproduce the case. Is your project using Stencil components from an NPM module or are you using Stencil components directly. This error message alone won't help us to start any investigations.

  2. added
    ionitron: needs reproduction
    and removed on Mar 3, 2024
  3. ionitron-bot commented on Mar 3, 2024

    @ionitron-bot

    Thanks for the issue! This issue has been labeled as needs reproduction. This label is added to issues that need a code reproduction.

    Please reproduce this issue in an Stencil starter component library and provide a way for us to access it (GitHub repo, StackBlitz, etc). Without a reliable code reproduction, it is unlikely we will be able to resolve the issue, leading to it being closed.

    If you have already provided a code snippet and are seeing this message, it is likely that the code snippet was not enough for our team to reproduce the issue.

    For a guide on how to create a good reproduction, see our Contributing Guide.

  4. benjaminmilcic commented on Mar 4, 2024

    @benjaminmilcic
    Author

    I don`t use Stencil directly. I never worked with it directly. I think it is used by Ionic.

    Here is my package.json

    { "name": "aznw-routes", "version": "0.0.0", "scripts": { "ng": "ng", "start": "ng serve", "build": "ng build", "watch": "ng build --watch --configuration development", "test": "ng test" }, "private": true, "dependencies": { "@angular/animations": "^17.1.0", "@angular/cdk": "^17.2.1", "@angular/common": "^17.1.0", "@angular/compiler": "^17.1.0", "@angular/core": "^17.1.0", "@angular/forms": "^17.1.0", "@angular/google-maps": "^17.2.1", "@angular/material": "^17.2.1", "@angular/platform-browser": "^17.1.0", "@angular/platform-browser-dynamic": "^17.1.0", "@angular/router": "^17.1.0", "@ionic/angular": "^7.7.3", "@ngx-translate/core": "^15.0.0", "@ngx-translate/http-loader": "^8.0.0", "@tinymce/tinymce-angular": "^7.0.0", "angular-resizable-element": "^7.0.2", "feiertagejs": "^1.4.0", "ng2-tooltip-directive": "^2.10.3", "ngx-toastr": "^18.0.0", "rxjs": "~7.8.0", "tslib": "^2.3.0", "zone.js": "~0.14.3" }, "devDependencies": { "@angular-devkit/build-angular": "^17.1.2", "@angular/cli": "^17.1.2", "@angular/compiler-cli": "^17.1.0", "@types/jasmine": "~5.1.0", "jasmine-core": "~5.1.0", "karma": "~6.4.0", "karma-chrome-launcher": "~3.2.0", "karma-coverage": "~2.2.0", "karma-jasmine": "~5.1.0", "karma-jasmine-html-reporter": "~2.1.0", "tailwindcss": "^3.4.1", "typescript": "~5.3.2" } }

    ng build worked before. Then I changed it to use angular routes and I added angular material and ionic.
    I remember that I also installated the pagage " postcss-import" and removed it again.
    ng serve worked well all the time. Then i made ng build and it breaks.

    Here is my tsconfig.js

    /* To learn more about this file see: https://angular.io/config/tsconfig. */ { "compileOnSave": false, "compilerOptions": { "outDir": "./dist/out-tsc", "forceConsistentCasingInFileNames": true, "strict": false, "noImplicitOverride": true, "noPropertyAccessFromIndexSignature": true, "noImplicitReturns": true, "noFallthroughCasesInSwitch": true, "skipLibCheck": true, "esModuleInterop": true, "sourceMap": true, "declaration": false, "experimentalDecorators": true, "moduleResolution": "node", "importHelpers": true, "target": "ES2022", "module": "ES2022", "useDefineForClassFields": false, "lib": [ "ES2022", "dom" ] }, "angularCompilerOptions": { "enableI18nLegacyMessageIdFormat": false, "strictInjectionParameters": true, "strictInputAccessModifiers": true, "strictTemplates": false } }

    Shall I provide other files here, like package-lock.json or so?

  5. alicewriteswrongs commented on Mar 4, 2024

    @alicewriteswrongs
    Contributor

    Hello @benjaminmilcic, this looks like it might be the same issue as #5389 which was fixed in Stencil v4.12.4. Ionic Framework, however, is currently using Stencil v4.12.3, so I think that may have to do with why you're seeing the error.

    To help us confirm that, could you provide a minimal reproduction case which showcases the issue? We aren't able to do much to help diagnose the issue without one. A minimal reproduction would be a git repository which includes the simplest project which showcases the problem, and will let us diagnose the issue and then test out a fix.

  6. benjaminmilcic commented on Mar 4, 2024

    @benjaminmilcic
    Author

    Ok, here are steps to reproduce:

    1. ng new
      (name: test)
      (style sheets: css)
      (no SSR)
    2. ng add @ionic/angular
    3. ng build

    ng version gives me:

    Angular CLI: 17.2.2
    Node: 20.11.0
    Package Manager: npm 10.2.4
    OS: win32 x64

    Angular: 17.2.3
    ... animations, common, compiler, compiler-cli, core, forms
    ... platform-browser, platform-browser-dynamic, router

    Package Version

    @angular-devkit/architect 0.1702.2
    @angular-devkit/build-angular 17.2.2
    @angular-devkit/core 17.2.2
    @angular-devkit/schematics 17.2.2
    @angular/cli 17.2.2
    @schematics/angular 17.2.2
    rxjs 7.8.1
    typescript 5.3.3
    zone.js 0.14.4

    ionic version gives me:
    7.2.0

    And here is a GitHub-Repo:
    [(https://github.com/benjaminmilcic/ionic-stencil-error)]

    Thanks a lot for the time to try helping...

  7. added
    Bug: Validated
    and removed
    ionitron: needs reproduction
    on Mar 4, 2024
  8. christian-bromann commented on Mar 4, 2024

    @christian-bromann
    Member

    I was able to clone the reproduction and saw the following warning in the build step:

    ▲ [WARNING] The glob pattern import("./**/*.entry.js*") did not match any files [empty-glob]
    
        node_modules/@stencil/core/internal/client/index.js:3808:2:
          3808 │   `./${bundleId}.entry.js${BUILD.hotModuleReplacement && hmrVers...
               ╵   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    

    I think this warning can be ignored however we should identify if @ionic/angular uses Stencils lazy components or DCE (dist-custom-elements) and if not, ensure this part of stencil is not imported anywhere.

    @benjaminmilcic we have ingested the issue into our backlog and will at it eventually. I unfortunately can't give you a timeline at this point but will make sure to post updates as we have it.

  9. benjaminmilcic commented on Mar 4, 2024

    @benjaminmilcic
    Author

    Can I ask you how I can make ng build with ignoring the warning and not break the build?

  10. papastepano commented on Mar 23, 2024

    @papastepano

    Thanks for rasing this issue. Experiencing the same problem, too.

  11. moh4sa commented on Apr 1, 2024

    @moh4sa

    experiencing the same problem, too.

  12. VerburgtJimmy commented on Apr 2, 2024

    @VerburgtJimmy

    Is there a temporary fix coming for this issue or even better a permanent fix. It's a bit weird to build a app for production with these kinds of warnings in them even though they are harmless. Thanks!

  13. 38 remaining items

  14. OS-jacobbell commented on Nov 19, 2025

    @OS-jacobbell
    Contributor

    I'm attempting to fix this warning and made an Ionic Framework dev build that works with the reproduction steps in this issue. It can be added to a project with

    ng add @ionic/angular@8.7.10-dev.11763578076.1047c3c7
    

    Please give it a try and let me know if it resolves the warning (or if it breaks anything!)

    PR is here for details on the change -> #6452

  15. guaycuru commented on Nov 19, 2025

    @guaycuru

    I'm attempting to fix this warning and made an Ionic Framework dev build that works with the reproduction steps in this issue. It can be added to a project with

    ng add @ionic/angular@8.7.10-dev.11763578076.1047c3c7
    

    Please give it a try and let me know if it resolves the warning (or if it breaks anything!)

    PR is here for details on the change -> #6452

    Hey!

    I just tested that dev build but unfortunately I'm still seeing the warn when building:

    Application bundle generation complete. [5.595 seconds]
    
    ▲ [WARNING] The glob pattern import("./**/*.entry.js*") did not match any files [empty-glob]
    
        node_modules/@stencil/core/internal/client/index.js:169:2:
          169 │   `./${bundleId}.entry.js${BUILD5.hotModuleReplacement && hmrVers...
              ╵   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
  16. JakobMadsen717 commented on Nov 19, 2025

    @JakobMadsen717

    Tested the @ionic/angular@8.7.10-dev.11763578076.1047c3c7

    The warning I had for many months on ng build is resolved = gone. My app seems to work just fine. Looks good to me & thanks for working on resolve.

  17. OS-jacobbell commented on Nov 19, 2025

    @OS-jacobbell
    Contributor

    Hi @guaycuru, I wonder if the dev build for Stencil did not get installed along with the Ionic dev build. Could you check your node_modules/@stencil/core/package.json and verify the version? It should be

    "name": "@stencil/core",
    "version": "4.38.3-dev.1763390030.f9ccdac",
  18. guaycuru commented on Nov 20, 2025

    @guaycuru

    Hi @guaycuru, I wonder if the dev build for Stencil did not get installed along with the Ionic dev build. Could you check your node_modules/@stencil/core/package.json and verify the version? It should be

    "name": "@stencil/core",
    "version": "4.38.3-dev.1763390030.f9ccdac",

    That was indeed the issue, @stencil/core's version was still "version": "4.38.0",
    After nuking node_modules and reinstalling everything the versions were correct and the warning was gone!
    Thank you so much, and I'm sorry for the false alarm!

  19. ch-ris commented on Jan 7, 2026

    @ch-ris

    If you're facing the same warning while waiting for long term fix:

    You can temporarily add override to package.json with mentioned version of "@stencil/core": "4.38.3-dev.1763390030.f9ccdac" that includes a fix #6452 that works for Esbuild while not limiting yourself to that specific Ionic dev version. But stay warned as that fix #6464 had to be reverted for now not to break webpack builds. Tested even with latest @ionic/angular 8.7.16

    If any override was used, I would strongly recommend setting some reminder or notification to remove it once fixed in future versions.

  20. trakhimenok commented on Feb 6, 2026

    @trakhimenok

    Is there a plan to implement a fix that would work for both esbuild and webpack?

  21. johnjenkins commented on Feb 6, 2026

    @johnjenkins
    Contributor

    @trakhimenok it's already in-place 😄 -
    ionic just need to add the enableImportInjection option to their config here

    This really isn't Stencil's issue - unfortunately I can't transfer it to ionic

  22. trakhimenok commented on Feb 6, 2026

    @trakhimenok

    @johnjenkins thanks, I've raised a bug with Ionic (see link above).

    P.S. I though Stencil was developed and is supported by Ionic team.

  23. johnjenkins commented on Feb 6, 2026

    @johnjenkins
    Contributor

    tysm!
    Stencil is more open-source led now.
    I have raised it with the ionic team previously (I think it's in their backlog) but it helps to have it publically viewable.

  24. OS-jacobbell commented on Feb 26, 2026

    @OS-jacobbell
    Contributor

    This should now be fixed for real in @ionic/angular@8.7.18 as a nice side effect of fixing a different issue, ionic-team/ionic-framework#30958

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug: Validated

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions