Skip to content

Location Report (SDK)

Available in the US and Canada

The Location Report provides a comprehensive summary of scores, points of interest, demographics, and more, for any location in the US or Canada. The report can be shared by URL or printed as a PDF.

The SDK provides a pre-built UI for launching or downloading the report. This is ideal for clients wanting to get setup quickly.

Screenshot of new Local Content SDK's onboarding interface

Getting started


First, install the entry script with npm, yarn, or pnpm:

npm i --save @local-logic/sdks-js
yarn add @local-logic/sdks-js
pnpm add @local-logic/sdks-js

The script is also available in umd and es format from the Local Logic CDN:<VERSION>/index.<FORMAT>.js

<VERSION> is the latest script version number (which you can find on npm), and <FORMAT> is either umd or es.



Step 1: Instantiate an LLSDKsJS instance

Import LLSDKsJS and create a new localLogicSDK instance. If you installed LLSDKsJS using a script tag, you must access it from the window object.

import LLSDKsJS from "@local-logic/sdks-js";
const localLogicSDK = LLSDKsJS(
// Your API key or token

Step 2: Instantiate a Location Report instance

Next, create an instance of Location Report. You must define a container element for it to render into.

// Define a container element
const container = document.createElement("div");
const options = {
lat: 37.8,
lng: -122.4,
addressLabel: "5605 Ave de Gaspé, Montreal, QC",
localLogicSDK.create("lat-entry", container, options);

React applications

The SDKs are designed to work with React and other declarative frameworks.


import { useRef, useEffect } from "react";
import LLSDKsJS from "@local-logic/sdks-js";
const localLogicSDK = LLSDKsJS(<API_KEY>);
function MyLocalContentComponent() {
const containerRef = useRef(null);
useEffect(() => {
if (!containerRef.current) {
const options = {
lat: 37.8,
lng: -122.4,
addressLabel: "5605 Ave de Gaspé, Montreal, QC"
const localContent = localLogicSDK.create(
// It is important to destroy the Local Content instance when the component is unmounted.
return () => {
}, []);
return (
<div ref={containerRef} />
export default MyLocalContentComponent;


latLatitudeStringWhen not using includeSearchAddress
lngLongitudeStringWhen not using includeSearchAddress
addressLabelLocation addressStringWhen not using includeSearchAddress
localeReport language"en" or "fr"
brokerNameMust also specify the brokerEmail and brokerPhoneString
brokerPhoneMust also specify the brokerName and brokerEmailString
brokerEmailMust also specify the brokerName and brokerPhoneString
brokerageNameMust also specify the brokerageLogo and brokerageWebsiteString
brokerageLogoURL to a png or jpg. Must also specify the brokerageName and brokerageWebsiteString
brokerageWebsiteMust also specify the brokerageName and brokerageLogoString
imageSDK banner pictureString
titleSDK titleString
textLine1SDK first line of textString
textLine2SDK second line of textString
buttonTextSDK button textString
includeSearchAddressAdds address search input which can be used in place of lat, lng and addressLabel. Ideal for non-listing pagesBoolean


Local Logic SDKs support visual customization using the Appearance API, which allows you to match the look of the SDK to your brand.


The SDKs currently offer two themes out of the box: day and night. The default mode is day, but you may wish to use the night theme if your application supports a dark mode.

const localLogicSDK = LLSDKsJS(
appearance: { theme: "night" }


The entire theme can be further customized using the variables option.

The following example changes the primary color, font, and gives the UI a more rounded appearance.

const localLogicSDK = LLSDKsJS(
appearance: {
variables: {
"--ll-color-primary": "#fd3958",
"--ll-color-primary-variant1": "#d5405b",
"--ll-border-radius-small": "8px",
"--ll-border-radius-medium": "16px",
"--ll-font-family": "Avenir, sans-serif",

You can find a list of appearance variables here.

Browser support

The SDKs are configured with to support these browsers.


The SDKs are designed to receive most new changes (non-breaking features and bug fixes) without the need for a developer to manually update the script.


Local Logic SDKs JS comes packaged with TypeScript declarations.


Q: How do I change the language of the SDK?

A: You can change the language by specifying locale in the LLSDKsJS options. The supported options are "en" and "fr".

const localContent = localLogicSDK.create(
containerRef.current, {
..., // Other config options here

Q: How do I disable lazy load?

A: Lazy loading is enabled by default. In some situations, you may want to disable lazy loading or control lazy loading with your own scripts.

To disable lazy load, pass lazy: false to the renderOptions parameter.

const localContent = localLogicSDK.create(
{ ... },
// renderOptions
lazy: false
© Local Logic 2023