JSPM

  • Created
  • Published
  • Downloads 60
  • Score
    100M100P100Q66894F
  • License MIT

System based on c# to javascript

Package Exports

  • system-x64
  • system-x64/dist/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (system-x64) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

What is system-x64?

system-x64 is a package that is based on C# conversions. Transacting functionally like DateTime.

Installing

npm i system-x64

or

yarn add system-x64

Convert

Using

import { Convert } from "system-x64";

import { Convert } from "system-x64";

console.log({
  toDate: Convert.toDate("24/02/2023", {
    culture: "pt-BR",
    default: new Date(),
  }),
  toNumber: Convert.toNumber("123.456,78", { culture: "pt-BR", default: 0 }),
  toBoolean: Convert.toBoolean("f"),
  toDecimal: Convert.toDecimal("123.456,78", { culture: "pt-BR", default: 0 }),
  toString: Convert.toString("test  "),
});

result:

{
  toDate: 2023-02-24T03:00:00.000Z,
  toNumber: 123.45678,
  toBoolean: false,
  toDecimal: 123.45678,
  toString: 'test'
}

License

MIT