Skip to content

If I create a directory with a name that starts with a dot, will the system not recognize it? #1805

@okathira

Description

@okathira

Describe the bug

I create a directory with a name that starts with a dot, will the system (Stackblitz or WebContainer? i dont know) not recognize it. chrome on windows.
like this,

await mkdir(`./.directory`, { recursive: true });

Since the mkdir function itself is working, I am reporting this problem as a “bug” rather than a “support” or “feature” problem.

Link to the blitz that caused the error

https://stackblitz.com/edit/stackblitz-starters-nwchkmq2?file=storybookScript.js,main.js

Steps to reproduce

  1. Open the link.
  2. Check current directory and files at this point.
  3. Run npm run main.
  4. Ensure that a directory with a name beginning with a dot is created but does not appear in the sidebar FILES.
  5. Save (or fork) project.
  6. Reload browser.
  7. Run ls -a to confirm that the directory has been removed.

Expected behavior

Created directory with a name that starts with a dot is also reflected in the GUI and saved.

Parity with Local

Screenshots

a created directory with a name beginning with a dot (.directory) does not appear in the GUI.
Image

Platform

Browser name  = Chrome
Full version  = 134.0.0.0
Major version = 134
navigator.appName = Netscape
navigator.userAgent = Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36
performance.memory = {
  "totalJSHeapSize": 129836947,
  "usedJSHeapSize": 123973911,
  "jsHeapSizeLimit": 4294705152
}
Hash = 33edf5bb

Additional context

same? #1439

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions