-
Notifications
You must be signed in to change notification settings - Fork 68
Description
On platform folder structure is a tad different from the open sourced LWC version.
On platform development has no concept of namespaces* (unless you're doing package development) and follows a generic folder structure of:
└── force-app/
└── main/
└── default/
└── lwc/
└── componentName/
├── componentName.css
├── componentName.html
├── componentName.js
└── componentName.js-meta.xml
Through config, the force-app/main/default path may be different. From what I can see in the documentation, the namespacing is expecting the LWCs parent directory to match with the component name.
<lwc-component-name/> is what wca currently would expect from the above folder structure, but the above component would be referenced via <c-component-name/> on platform (c being the default namespace).
On platform development features an sfdx-project.json file to configure package paths. Off platform has the lwr.config.json or lwc.config.json to define namespaces and package folders. Would be neat if these config files could be used to determine if it is a valid LWC vs custom logic around parent folder names.