Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
haystack-codegen
Advanced tools
This project is classed as experimental!
Generates TypeScript code for haystack-core using haystack 4 defs.
Please click here for the API documentation.
Please click here for the generated typedoc information for all defs.
npm install haystack-codegen
Or to install globally...
npm install haystack-codegen --global
Use the -t
option to specify a space separated list of tags. For example, to create all the TypeScript code for a site
and ahu
tag...
defcodegen -t site ahu
If you want to generate TypeScript for all of the tags in a defs database run...
defcodegen -t *all*
Tip: try running typedoc
on the generated code for some nice looking HTML documentation!
The tool runs relative to the directory it is run in. The default generated file path is ./src/haystack/types.ts
. An alternative file can be specified via the -f
option...
defcodegen -t site ahu -f ./src/foo/bar.ts
The tool uses defs to generate TypeScript code. The defs database can be specified in a number of ways. By default...
FIN_HOME
environment variable. If found, the defs will be compiled from the $FIN_HOME/lib/pod
directory.FAN_HOME
environment variable. If found, the defs will be compiled from the $FAN_HOME/lib.fan
directory. In this scenario only POD files that start with ph
will be used.haystack-codegen
. Please note, this library could easily become out of date quickly.Due to the dynamic nature of defs, the most commonly used way is to load defs from a running server.
Ensure server authentication is disabled when doing this (for FIN/SkySpark use the -noAuth
option on start up).
For instance, to generate the TypeScript code for the site
tag from a server's demo project...
defcodegen -t site -u http://localhost:8080/api/demo
For more information on command line options run defcodegen --help
.
FAQs
Project Haystack Core code generation tools
The npm package haystack-codegen receives a total of 964 weekly downloads. As such, haystack-codegen popularity was classified as not popular.
We found that haystack-codegen demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.