I am working on a project which uses MEAN stack. Since this project will be deployed on client system, we want to make Angular part as executable (.exe) file. We have already made Nodejs part executable by using 'pkg'. The intention behind is to make it easy to execute and complete code is not visible to the client.
Asked
Active
Viewed 838 times
-1
-
2Are you working on a desktop project with angular? Consider using electron to build it to a Windows desktop project. – Anduin Xue Oct 17 '19 at 06:25
-
1You will have to consider [electron](https://electronjs.org/) for this case – Dino Oct 17 '19 at 06:27
2 Answers
1
For the executable part (e.g. running as a desktop app), Electron might be a good choice: https://electronjs.org/
As for hiding the code, you could probably use a code obfuscation tool (e.g. https://obfuscator.io/). But in general, it's pretty difficult to hide JavaScript code. See this answer for more detail.

eronisko
- 1,862
- 1
- 15
- 14
0
I would definitely look into using an Electron & Angular boilerplate: https://github.com/maximegris/angular-electron
In terms of obfuscation I just made an npm package that obfuscates and minifies the code in a package so that electron can properly build it. https://www.npmjs.com/package/directory-obfuscator