UNPKG

nortax-ts

Version:

Norwegian Tax Calculator - TypeScript Implementation

30 lines (29 loc) 1.02 kB
/** * nortax-ts * A TypeScript port of nortax (https://github.com/lewiuberg/nortax) * Original Copyright (c) 2023 Lewi Lie Uberg * TypeScript port Copyright (c) 2024 Arild Langtind * Licensed under the MIT License */ import { IncomeType, Period } from './types'; import { ValidTablesTo2019, ValidTables2020To2024, ValidTables2025 } from './types'; type ValidTable = ValidTablesTo2019 | ValidTables2020To2024 | ValidTables2025; export declare class Tax { private grossIncome; private taxTable; private incomeType; private period; private year; private returnWholeTable; private url; constructor(grossIncome?: number, taxTable?: ValidTable, incomeType?: IncomeType, period?: Period, year?: number); private makeApiCall; private updateUrl; getDeduction(): Promise<number>; getNetIncome(): Promise<number>; getWholeTable(): Promise<Record<string, number>>; getFullDetails(): Promise<string>; toString(): string; [Symbol.toStringTag](): string; } export {};