-
Notifications
You must be signed in to change notification settings - Fork 402
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: CSS only modules #1211
feat: CSS only modules #1211
Conversation
Benchmark resultsBase commit: lwc-engine-benchmark
|
Benchmark resultsBase commit: lwc-engine-benchmark
|
@@ -14,7 +14,7 @@ const EMPTY_IMPLICIT_CSS_CONTENT = ''; | |||
const EMPTY_IMPLICIT_HTML_CONTENT = 'export default void 0'; | |||
const IMPLICIT_DEFAULT_HTML_PATH = '@lwc/resources/empty_html.js'; | |||
const IMPLICIT_DEFAULT_CSS_PATH = '@lwc/resources/empty_css.css'; | |||
const VALID_EXTENSIONS = ['.js', '.ts']; | |||
const VALID_EXTENSIONS = ['.js', '.ts', '.html', '.css']; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
html too?
@@ -106,6 +99,16 @@ export function applyStyleAttributes(vm: VM, hostAttribute: string, shadowAttrib | |||
context.shadowAttribute = shadowAttribute; | |||
} | |||
|
|||
function collectStylesheets(stylesheets, hostSelector, shadowSelector, isNative, fn) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
call fn -> aggregatorFn or something more specific
also add some notes to explain the why
@@ -13,7 +13,7 @@ import nodeModulePaths from './node-modules-paths'; | |||
|
|||
const DEFAULT_IGNORE = ['**/node_modules/**', '**/__tests__/**']; | |||
const PACKAGE_PATTERN = ['*/*/package.json', '*/package.json', 'package.json']; | |||
const MODULE_ENTRY_PATTERN = `**/*.[jt]s`; | |||
const MODULE_ENTRY_PATTERN = `**/*.([jt]s|html|css)`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
html?
Preparing for the html only :)
…On Tue, May 7, 2019 at 10:36 PM Caridy Patiño ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In ***@***.***/module-resolver/src/index.ts
<#1211 (comment)>:
> @@ -13,7 +13,7 @@ import nodeModulePaths from './node-modules-paths';
const DEFAULT_IGNORE = ['**/node_modules/**', '**/__tests__/**'];
const PACKAGE_PATTERN = ['*/*/package.json', '*/package.json', 'package.json'];
-const MODULE_ENTRY_PATTERN = `**/*.[jt]s`;
+const MODULE_ENTRY_PATTERN = `**/*.([jt]s|html|css)`;
html?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1211 (review)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAI7JKAEFZ6GB5W3MEQOTQ3PUI4EBANCNFSM4HLK7DNQ>
.
|
The flapper can be ignored:
|
ops, closed accidentally, diego will reopen it. |
Details
This PRs allow to define CSS only modules.