New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@holaluz/pomada

Package Overview
Dependencies
Maintainers
4
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@holaluz/pomada

Holaluz shared FE business logic repository

  • 2.4.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
4
Created
Source

Pomada

A shared FE business logic repository.

Quick start

Install the library:

npm i @holaluz/pomada

Import and execute the use case you need. For example, getting prices of the products of a supply point:

import { getProductPrices, getSupplyPoint } from '@holaluz/pomada'

getSupplyPoint(
  {
    cups: 'example cups',
  },
  {
    onSuccess(supplyPoint) {
      getProductPrices(
        {
          products: supplyPoint.contractableProducts,
          consumption: supplyPoint.consumption,
          currentPower: supplyPoint.currentPower,
          desiredPower: supplyPoint.optimizedPower,
          optimizedPower: supplyPoint.optimizedPower,
        },
        {
          onSuccess(prices) {
            console.log(prices)
          },
          onError(error) {
            console.log(error)
          },
        }
      )
    },
    onCupsAlreadyClient(supplyPoint) {
      console.log(supplyPoint)
    },
    onCupsInvalid(cupsError) {
      console.log(cupsError)
    },
  }
)

For a more in-depth documentation, check the docs.

Usage for staging or production

This library reads a process.env.ENV variable, and access staging APIs if ENV = staging or production APIs if ENV = production.

Development

Use Visual Studio Code. Execute and debug code with its included Typescript debugger (pressing F5).

Documentation is generated automatically for every use case and models inside src. Check out Typedoc for the available options.

Documentation.

Npm Package.

Repository.

FAQs

Package last updated on 21 Apr 2023

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc