Is is possible to use javascript in ionic 5

help me to find a better solution to use javascript in ionic

If you mean “as opposed to TypeScript”, while you wait for somebody who shares your opinion to chime in, I’d like to try to convince you to change your mind.

One of the most important things we can do as developers is to detect problems as early as possible, so that they can be fixed before they get out into the wild and people have to report them and track the fixes and figure out what those fixes broke and so forth. In JavaScript, every error is a runtime error. TypeScript moves a lot of those to build time: even the ones you don’t see until unusual combinations of data get involved.

Another super-important thing we can do is to document our code. Most all of the options you have here for JavaScript are out-of-band comments, which provide no guarantee that they actually describe what the code does. When you write in TypeScript, and are vigilant about typing everything, the code documents itself (and cannot lie to you as easily). Your IDE can now steer you clear of creating many different classes of bugs in the first place.

Finally, I’d like to urge you to pick a framework. I use Angular, but Ionic has other options: React or Vue. Don’t fall into the trap of thinking that learning frameworks isn’t worthwhile: you’ll eventually end up effectively writing your own, and no matter how skilled and visionary you are, you won’t be able to compete with teams of dedicated framework engineers and the legions of users and contributors that have iteratively built today’s web app frameworks.

1 Like