問題タブ [angular-components]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
angular - Angular 2+ の ngShow と ngHide に相当するものは何ですか?
特定の条件下で表示したい要素がいくつかあります。
AngularJS では、次のように記述します。
Angular 2+でこれを行うにはどうすればよいですか?
css - 親コンポーネントのCSSファイルから子コンポーネントをスタイルする方法は?
私は親コンポーネントを持っています:
そして、このグループに子コンポーネントを追加したいと思います:
親テンプレート:
子テンプレート:
parent
とは 2 つの別個のコンポーネントであるためchild
、それらのスタイルは独自のスコープにロックされています。
私の親コンポーネントで私はやってみました:
しかし、スタイルはコンポーネント.child
に適用されていません。child
スコープの問題を解決するために、のスタイルシートをコンポーネントstyleUrls
に含めるために使用してみました:parent
child
しかし、それは役に立ちませんでした。また、child
スタイルシートをフェッチして別の方法を試しましたparent
が、どちらも役に立ちませんでした。
では、親コンポーネントに含まれる子コンポーネントのスタイルをどのように設定するのでしょうか?
angularjs - angularコンポーネントの「バインディング」パラメータの何が問題になっていますか?
ページに含めたい角度のあるコンポーネントがあります。このコンポーネントのbindingsパラメータをコメント/削除すると、すべてが機能します...なぜですか?
バインディングパラメーターを使用したい場合、次のエラーが発生します。
リンク先: https://docs.angularjs.org/error/ $compile/iscp?p0=detailsComponent1&p1=value&p2=Component1&p3=controller%20bindings%20definition
どういう意味ですか ??
ありがとう。
angularjs - Angular JS - カスタム フィルター - 競合状態エラー
さて、私の問題は単純です。競合状態エラーです。フィルターが使用しようとすると配列が作成されませんが、ページがすべてをロードして正常に動作すると、このようにページが完全にロードされる前にコンソールにいくつかのエラーが表示されます:
そして、私が持っている他の質問は、なぜこのエラーが13回表示されるのですか?? 自分では対応できません。
これが私のコードです:
テンプレート HTML
モジュールの作成:
コントローラー (コンポーネント定義)
javascript - Configure ui-router with components containing multiple bindings
I am trying to find a better solution to use the ui-router
together with angular components
.
Consider two simple components:
Right now, I am specifying the component and its parameter using the template
property:
While this is working fine, I have components with arround ten bindings which makes the configuration of the ui-router
realy awkward.
I tried using the component
property but this doesn't work for me at all. The only other solution I found is to specify the parent using the require
property and omit the bindings - but this doesn't feel right for me... Is there a better way to do this?
Here is a plnkr.