How to use @0x/contracts-erc721 - 5 common examples

To help you get started, we’ve selected a few @0x/contracts-erc721 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github 0xProject / 0x-monorepo / packages / migrations / src / migration.ts View on Github external
// tslint:disable-next-line:no-unused-variable
        const dummyErc20Token = await DummyERC20TokenContract.deployFrom0xArtifactAsync(
            artifacts.DummyERC20Token,
            provider,
            txDefaults,
            artifacts,
            token.name,
            token.symbol,
            token.decimals,
            totalSupply,
        );
    }

    // ERC721
    // tslint:disable-next-line:no-unused-variable
    const cryptoKittieToken = await DummyERC721TokenContract.deployFrom0xArtifactAsync(
        artifacts.DummyERC721Token,
        provider,
        txDefaults,
        artifacts,
        erc721TokenInfo[0].name,
        erc721TokenInfo[0].symbol,
    );

    // 1155 Asset Proxy
    const erc1155Proxy = await ERC1155ProxyContract.deployFrom0xArtifactAsync(
        artifacts.ERC1155Proxy,
        provider,
        txDefaults,
        artifacts,
    );
github 0xProject / 0x-monorepo / contracts / asset-proxy / src / erc721_wrapper.ts View on Github external
public async deployDummyTokensAsync(): Promise {
        // tslint:disable-next-line:no-unused-variable
        for (const i of _.times(constants.NUM_DUMMY_ERC721_TO_DEPLOY)) {
            this._dummyTokenContracts.push(
                await DummyERC721TokenContract.deployFrom0xArtifactAsync(
                    erc721Artifacts.DummyERC721Token,
                    this._provider,
                    txDefaults,
                    artifacts,
                    constants.DUMMY_TOKEN_NAME,
                    constants.DUMMY_TOKEN_SYMBOL,
                ),
            );
        }
        return this._dummyTokenContracts;
    }
    public async deployProxyAsync(): Promise {
github 0xProject / 0x-monorepo / contracts / asset-proxy / src / erc721_wrapper.ts View on Github external
public async deployDummyTokensAsync(): Promise {
        // tslint:disable-next-line:no-unused-variable
        for (const i of _.times(constants.NUM_DUMMY_ERC721_TO_DEPLOY)) {
            this._dummyTokenContracts.push(
                await DummyERC721TokenContract.deployFrom0xArtifactAsync(
                    erc721Artifacts.DummyERC721Token,
                    this._provider,
                    txDefaults,
                    artifacts,
                    constants.DUMMY_TOKEN_NAME,
                    constants.DUMMY_TOKEN_SYMBOL,
                ),
            );
        }
        return this._dummyTokenContracts;
    }
    public async deployProxyAsync(): Promise {
github 0xProject / 0x-monorepo / contracts / integrations / src / deployment_mananger.ts View on Github external
protected static async _deployTokenContractsAsync(
        environment: BlockchainTestsEnvironment,
        txDefaults: Partial,
    ): Promise {
        const erc20 = await ERC20TokenContract.deployFrom0xArtifactAsync(
            ERC20Artifacts.ERC20Token,
            environment.provider,
            txDefaults,
            ERC20Artifacts,
        );

        const erc721 = await ERC721TokenContract.deployFrom0xArtifactAsync(
            ERC721Artifacts.ERC721Token,
            environment.provider,
            txDefaults,
            ERC721Artifacts,
        );

        const erc1155 = await ERC1155Contract.deployFrom0xArtifactAsync(
            ERC1155Artifacts.ERC1155,
            environment.provider,
            txDefaults,
            ERC1155Artifacts,
        );

        const weth = await WETH9Contract.deployFrom0xArtifactAsync(
            ERC20Artifacts.WETH9,
            environment.provider,
github 0xProject / 0x-monorepo / contracts / integrations / src / deployment_mananger.ts View on Github external
protected static async _deployTokenContractsAsync(
        environment: BlockchainTestsEnvironment,
        txDefaults: Partial,
    ): Promise {
        const erc20 = await ERC20TokenContract.deployFrom0xArtifactAsync(
            ERC20Artifacts.ERC20Token,
            environment.provider,
            txDefaults,
            ERC20Artifacts,
        );

        const erc721 = await ERC721TokenContract.deployFrom0xArtifactAsync(
            ERC721Artifacts.ERC721Token,
            environment.provider,
            txDefaults,
            ERC721Artifacts,
        );

        const erc1155 = await ERC1155Contract.deployFrom0xArtifactAsync(
            ERC1155Artifacts.ERC1155,
            environment.provider,
            txDefaults,
            ERC1155Artifacts,
        );

        const weth = await WETH9Contract.deployFrom0xArtifactAsync(
            ERC20Artifacts.WETH9,
            environment.provider,
            txDefaults,

@0x/contracts-erc721

Token contracts used by 0x protocol

Apache-2.0
Latest version published 3 years ago

Package Health Score

57 / 100
Full package analysis