Skip to main content

signUp

A convenience method that calls and is equivalent to fcl.authenticate().

This method can only be used in web browsers.

Import

You can import the entire package and access the function:


_10
import * as fcl from "@onflow/fcl"
_10
_10
fcl.signUp(opts)

Or import directly the specific function:


_10
import { signUp } from "@onflow/fcl"
_10
_10
signUp(opts)

Usage


_10
import * as fcl from '@onflow/fcl';
_10
fcl.config()
_10
.put('accessNode.api', 'https://rest-testnet.onflow.org')
_10
.put('discovery.wallet', 'https://fcl-discovery.onflow.org/testnet/authn');
_10
_10
// User clicks sign up button
_10
fcl.signUp();

Parameters

opts (optional)

  • Type: {}
  • Description: Authentication options passed to authenticate method

Returns

Promise<CurrentUser>

Promise that resolves to the authenticated CurrentUser object or undefined


Rate this page