Socket
Book a DemoInstallSign in
Socket

@aaronhayes/react-use-hubspot-form

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aaronhayes/react-use-hubspot-form

Embed HubSpot forms into your React components using hooks! Works with Create React App, Gatsby and other platforms.

Source
npmnpm
Version
1.2.2
Version published
Weekly downloads
12K
19.97%
Maintainers
1
Weekly downloads
 
Created
Source

React Use HubSpot Form Embed

npm (scoped) Bundle Size License

Embed HubSpot forms into your React components using hooks! Works with Create React App, Gatsby and other platforms.

Install

$ npm install --save @aaronhayes/react-use-hubspot-form
$ yarn add @aaronhayes/react-use-hubspot-form

Usage

import React from 'react';

import useHubspotForm from '@aaronhayes/react-use-hubspot-form';

const MyPage = () => {
    const { loaded, error, formCreated } = useHubspotForm({
        portalId: 'XXXXXXX',
        formId: 'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX',
        target: '#my-hubspot-form'
    });

    return (
        <div>
            <h1>Embed Form Below</h1>
            <div id="my-hubspot-form"></div>
        </div>
    )
}

Keywords

react

FAQs

Package last updated on 10 Nov 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts