I don’t think those are scripts to go into a front-end package. Those scripts are the ones you run with commands like
yarn run build:core
So it’s basically stuff to build the front-end, not stuff to go into the front-end bundle. You can see by the existing scripts, they’re not js files, they’re npm and ng commands.
You probably need to build an entire front-end extension as described here:
but this will only make sense if you know how your code will run, how it will be triggered, and it can’t be the familiar JS / JQuery-style event triggers - it has to be Angular actions tied to the specific SuiteCRM front-end…
Thanks for answering. The purpose of including this custom script is to try to apply custom validations on some fields. I plan to interact with the DOM in order to achieve this goal. Specifically to handle this scenario
I don’t think you can play outside the framework like that…
You need to do it the Angular way. Which I can’t teach you, because I don’t know.
There is already front-end code for validations, you can find it in several places. If you need some extension to that code, you really need to think in terms of “front-end extension”, not JS hack.
In the short run, this makes small customizations much harder. In the long run, we get a consistent front-end where things don’t fall apart chaotically for no good reason…