diff --git a/README.md b/README.md index 76fe375..92e873c 100644 --- a/README.md +++ b/README.md @@ -199,7 +199,7 @@ import 'alpinejs'; - We import Alpine *after* this package
-resources/js/search.js +resources/js/search.ts ```ts import { AlpineComponent } from '@leanadmin/alpine-typescript'; @@ -316,7 +316,7 @@ export default class Search extends AlpineComponent {
-**`search.js` highlights:** +**`search.ts` highlights:** - We `export default` the class - We have to call `super()` if we define a constructor - Sometimes, we have to use `as HTMLElement` because the DOM API can return `Element` which doesn't have methods like `focus()`