nativescript-textinputlayoutは "バニラ" NativeScriptコンポーネントです。これをAngularで使用するには、element registry APIを使用してAngularテンプレートの有効なタグとして登録する必要があります。
例:
私-component.component.ts
import { registerElement } from "nativescript-angular/element-registry";
registerElement("TextInputLayout",() => require("nativescript-textinputlayout").TextInputLayout);
@Component({
selector: "my-component",
moduleId: module.id,
templateUrl: "./my-component.component.html"
})
export class MyComponent {}
私-component.component.htmlプラグインは、あなたがよされ
<StackLayout>
<TextInputLayout hint="my hint" hintAnimationEnabled="true">
<TextField text="my content"></TextField>
</TextInputLayout>
</StackLayout>
必要。私はそのプラグインを使用する正確なスニペットを持っていませんが、角度https://github.com/bradmartin/nativescript-drawingpad/blob/master/README.md#angularのuiプラグインを使用するサンプルがあります。あなたが必要とする 'registerElement()'になります。 –
本当に助けてくれてありがとう! –
@OmarEssamあなたはそれをどのようにスニペットを投稿できますか?私はいくつかの並べ替えエラーが発生しています。ありがとう – Dlucidone