Proxy Factory

Library to create clones of a contract. This is used by the NFTCompanyFactory to mint NFTs from a template/extension.

Functions

_create

Creates a clone of the given contract.

Params:

Name

Type

Description

logic

address

Address of the contract to clone

data

bytes

Any init functions to call

Returns:

Name

Type

Description

proxy

address

Address of the newly deployed clone

_create2

Creates a clone of the given contract with salted deterministic deployment.

Params:

Name

Type

Description

logic

address

Address of the contract to clone

data

bytes

Any init functions to call

salt

bytes32

Random salt. Using the same salt and same logic for multiple creates will fail.

Returns:

Name

Type

Description

proxy

address

Address of the newly deployed clone