Comment on page
Getting Started
Getting started with @motor-js/nebula
The fastest way to get started is to install via npm.
npm i @motor-js/nebula @motor-js/engine
Start by wrapping your application with the Motor (from our engine package) and NebulaConnection components, at the root of your project. This handles connection to the Qlik engine and is needed for the components in your application to work.
You need to use the Motor component from
@motor-js/engine
in order for the nebula package to work. The Motor component establishes the connection to your Qlik app.// 1. Import the Motor component
import { Motor } from @motor-js/engine
import { NebulaConnection } from @motor-js/nebula
function App() {
return (
// 2. Use at the root of your project
<Motor
config={
host: "myqliksite.qlik.com",
secure: true,
port: 433,
prefix: "",
appId: 'myAwesomeApp',
}
>
<NebulaConnection>
<App />
</NebulaConnection>
</Motor>
)
}
Next, import the NebulaContainer component and you are good to go
import { NebulaContainer } from "@motor-js/nebula"
const Component = () => {
return (
<div>
<NebulaContainer
render={{
id: 'objectIdFromQlikApp'
}}
styles={{
width: '80%',
height: 400,
paddingTop: 50,
}}
/>
</div>
);
};
Last modified 2yr ago