@felipebri23/3ds2-integrated-server-test
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

3DSv2.js

This project wraps our vendor's MPI Javascript libraries (as of 17th April 2019 just Cardinal Commerce).

It uses Typescript v3.4+ and rollup.js to generate a bundled Javascript file that contains our library and all its dependencies.

It was based on rollup's Typescript library template


Requirements

Visual Studio Code:

To build the JavaScript:

  • Installing Docker locally (18.06+)
  • or installing NodeJS locally (10.10+)

Development workfow

npm i
npm run dev

# That's it!

The dev npm script watches for changes, generates inlined sourcemaps and starts an HTTP server (port 8080) to serve the generated JS file.


How to build

  • Docker & GitBash (preferred):

    docker build -t registry.payvision.com/internal-mpi-js-builder .
    
    MSYS_NO_PATHCONV=1 docker run --rm -it -v $PWD/dist:/dist registry.payvision.com/internal-mpi-js-builder
    
    # Optional
    docker rmi registry.payvision.com/internal-mpi-js-builder
  • Node:

    npm i
    npm run build

In both scenarios a 3ds2integratedserver.js will be place inside the dist folder.

Why is Docker preferred?

Simply because it doesn't pollute the environment and helps making builds reproducible.


Troubleshooting

ERROR2000 Invalid call, something went wrong with the library's internals.

If you get this error, it means your state table, located in main.ts needs to be updated with new and/or renamed states.

Readme

Keywords

none

Package Sidebar

Install

npm i @felipebri23/3ds2-integrated-server-test

Weekly Downloads

0

Version

1.0.0

License

none

Unpacked Size

39.1 kB

Total Files

3

Last publish

Collaborators

  • felipebri23