Skip to content

[Features Request] Import folder modules in auto require by folder name instead or beside of init #875

@sewbacca

Description

@sewbacca

Given such a folder structure:

.
└── module
    ├── init.lua
    └── submodule
        └── init.lua

Now in module/init.lua i would like to import submodule. Currently it only works if I try to import it via init:

weird-imports

However it would be nice to import them as submodule as the foldername would suggest:

2021-12-24 01_07_34-Window

P.S. Side notice, in my demonstration test I noticed, returning a string in module/submodule/init.lua won't show up in autocompletion suggestions when typing init.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions