1.0.8 • Published 3 years ago

user-class v1.0.8

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

��# User Class

Create a user object

Installation

npm i user-class

Usage

const User = require("user-class")

const Bob = new User("Bob", "Smith", 23124, 20)

Documentation

Create user

const Bob = new User("Bob", "Smith", 23124, 20)

Get first name | Returns a string

Bob.getFirstName() // Returns "Bob"

Get last name | Returns a string

Bob.getLastName() // Returns "Smith"

Get full name | Returns a string

Bob.getLastName() // Returns "Bob Smith"

Get id | Returns a number

Bob.getId() // Returns 23124

Get age | Returns a number

Bob.getAge() // Returns 20

Get user object

Bob.getUserObject() // Returns 20

Returns an object

{
  firstName: 'Bob',
  lastName: 'Bob',
  fullName: 'Bob Bob',
  id: 214134,
  age: 20
}
1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago