LoginSignup
2
0

LWC関連(トレイルヘッド含む)のまとめ

Last updated at Posted at 2022-02-22

まとめページに戻る

少し関連情報を整理します。

操作方法等の覚え

PATH 変数を確認すると、インストール先が判断できると思います。そこにアンインストール用のバッチファイルとかはないですか?

https://www.reddit.com/r/SalesforceDeveloper/comments/16dn1v4/cant_uninstall_sfdx_windows/

活用例

コーディングサンプル

image.png

調べてみると似たような現象の解説がありますね。

LWCでテーブルの行コンポーネントがうまく表示されなかったので、display:table-row;した
https://zenn.dev/hrk623/articles/fa0770aabccb26

image.png

以下に回避策が説明されています。参考になると思います。

Is attribute 'allowfullscreen' of iframe unavailable in Lightning component?
https://salesforce.stackexchange.com/questions/161892/is-attribute-allowfullscreen-of-iframe-unavailable-in-lightning-component

lwc:if={!condition}と思ったのですが... 違うみたいですね。
何やらサポートされて無さそうな感じです。

what if we want to render if the flag is false? i am trying to set it lwc:if={!condition} OR lwc:if={condition == false} but it does not work

You will have to create yet another getter function in JavaScript.

https://salesforce.stackexchange.com/questions/327591/is-it-possible-to-use-expressions-in-iftrue-or-iffalse-tag-in-lwc

Complex expressions like !condition or object?.property?.condition aren’t supported. To evaluate complex expressions, use a getter in your JavaScript class.

https://www.apexhours.com/conditional-rendering-in-lwc-using-lwcif-and-lwcelse/

その他

CSS サンプル

インストール

CLIのバージョンダウンで解決

I was able to resolve this issue by overriding the Salesforce CLI apiversion back to 54.0 when running the package version create command.

この問題は、パッケージ バージョン作成コマンドの実行時に Salesforce CLI の API バージョンをオーバーライドして 54.0 に戻すことで解決できました。

deployが遅い

I gave up and just created a new sandbox. Deploying a class file is taking less than 5 seconds in the new sandbox which is tolerable.

諦めて新しいサンドボックスを作成しました。新しいサンドボックスでは、クラス ファイルのデプロイにかかる時間は 5 秒未満ですが、許容できる範囲です

Json でのエラー

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0