Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@vendasta/core

Package Overview
Dependencies
Maintainers
1
Versions
772
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vendasta/core

Services for vendasta angular applications

  • 0.0.3
  • npm
  • Socket score

Version published
Weekly downloads
18
decreased by-37.93%
Maintainers
1
Weekly downloads
 
Created
Source

Partner Service

This provides a service for other components to use to retrieve partner information.

Requirements

The Partner Service interface:

export interface PartnerServiceInterface {
  getPartnerId(): Observable<string>;
}

To implement the interface make a new service that implements the interface:

import {PartnerServiceInterface} from '@vendasta/partner-service';

@Injectable()
export class PartnerService implements PartnerServiceInterface {
  …
  getPartnerId(): Observable<string> {
    // Implement how the project determines which partner id the current context is in
  }
}

Next you will need to provide your service as that interface (generally in app.module.ts)

import { PartnerService } from './partner.service';
import { PartnerServiceInterfaceToken } from '@vendasta/partner-service';
…
@NgModule({
  …
  providers: [
    PartnerService, {provide: PartnerServiceInterfaceToken, useExisting: PartnerService}
  ],
})
  • Note: To be able to inject an interface, you will have to provide the InjectionToken and not the interface itself (PartnerServiceInterfaceToken vs PartnerServiceInterface).

FAQs

Package last updated on 12 Sep 2017

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