Skip to content

index.js? #1

@fat

Description

@fat

Not sure if this would be possible... but in node, something that I really like is being able to specify an index.js file, which will load when a directory is passed to require.

Soo... if you had directory foo in your root, which contained an index.js file, you could load it by doing:

var foo = require('foo');

This could be nice when you're trying to avoid stuff like:

using ('components/modal/modal', function () {}); //where modal.js is one of many modal files

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions