Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@fauna-labs/fql-utilities
Advanced tools
A library of FQL utilities for Fauna Schema Migrate, implemented in TypeScript.
This repository contains unofficial patterns, sample code, or tools to help developers build more effectively with Fauna. All Fauna Labs repositories are provided “as-is” and without support. By using this repository or its contents, you agree that this repository may never be officially supported and moved to the Fauna organization.
This repo contains code for user-defined functions (UDFs) to accomplish common tasks in Fauna. These UDFs are designed to be deployed with Fauna Schema Migrate.
npm init -y
npm install faunadb
npm install --save-dev @fauna-labs/faunadb-schema-migrate
npm install --save-dev @fauna-labs/fql-utilities
npx fauna-schema-migrate init
tail.js
in the fauna/resources
directory with the following code:
import { Tail } from '@fauna-labs/fql-utilities';
export default Tail();
npx fauna-schema-migrate generate
npx fauna-schema-migrate apply
This creates a UDF named Tail()
in your database. Tail()
accepts one parameter, an Array, and returns a new array consisting of every element except the first. If the array is empty, Tail()
returns an empty array.
You can then call the Tail UDF with the following code:
Let(
{
array: [0, 1, 2],
shortArray: Call("Tail", Var("array"))
},
Equals(Count(Var("shortArray")), 2) // true
)
FAQs
A library of FQL utilities for Fauna Schema Migrate, implemented in TypeScript.
We found that @fauna-labs/fql-utilities demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.