twID

package module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 22, 2023 License: MIT Imports: 4 Imported by: 0

README

twID

The twID package provides a function for verifying Taiwan national identification numbers. This is useful for validating the format and checksum of the ID number.

Installation

You can install the twID package using go get:

go get github.com/r567tw/twID

Usage

Here's an example of how to use the twID package:

package main

import (
	"fmt"
	"github.com/r567tw/twID"
)

func main() {
	id := "A123456789"

	if twID.Verify(id) {
		fmt.Printf("%s is a valid Taiwan national identification number.\n", id)
	} else {
		fmt.Printf("%s is not a valid Taiwan national identification number.\n", id)
	}
}

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT

Documentation

Overview

Package twID provides a function to verify Taiwanese ID numbers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Verify

func Verify(IDNumber string) bool

Verify checks if a Taiwanese ID number is valid or not. Returns true if the ID number is valid, otherwise false.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL