Closed lukethacoder closed 1 year ago
@jmsjtu
@lukethacoder I don't think you can set LWC compiler options using lwr.config.json
. I'll check with the LWR team to see if there is a way to set the options but I don't think they allow you to configure it.
Also the new dynamic components feature is scheduled to be GA in Winter24
, at which point you should be able to use it without any additional configuration.
If you want to test out the feature in the meantime, you can use the LWC OSS compiler directly.
@jmsjtu no problem if it's not supported. Was poking around in this repo looking at the config for the @lwc/*
packages and thought it might/should work.
Happy to close this if it is not meant to be exposed to the lwr.config.json
@lukethacoder looks like compiler options are not supported in lwr.config.json
.
all good. happy to close this. Keen for Winter24
to use the new dynamic components in LWR.
Description
Compiler error is thrown even when
experimentalDynamicDirective
andenableDynamicComponents
are set to true in thelwr.config.json
file.CompilerError: LWC1188: Invalid dynamic components usage, lwc:component and lwc:is can only be used when dynamic components have been enabled.
Steps to Reproduce
lwr.config.json
app.html
app.js
Expected Results
No error is thrown an able to use
lwc:component
andlwc:is
instead of the olderlwc:dynamic={dynamicCtor}
syntaxActual Results
Version
Possible Solution
Are compiler config values not promoted to the
@lwc/template-compiler
?