An example project showcasing how to use Flows with Angular to build native product growth experiences.
This example extends the Angular starter project with the @flows/js and @flows/js-components packages to demonstrate how to integrate Flows into your application.
In flows.service.ts you can find Flows service that is imported to app.ts and is initialized in the browser during the ngOnInit() lifecycle method. In app.html - <flows-floating-blocks> is added to render floating components.
The @flows/js-components package includes ready-to-use components to build in-app experiences. Refer to flows.service.ts to learn how to import and use these components.
Extend Flows by creating your own components for workflows and tours:
- Workflow block: The
banner.tsfile demonstrates a customBannercomponent withtitle,body, and acloseprop connected to an exit node. - Tour block: The
tour-banner.tsfile shows how to build aTourBannercomponent. It acceptstitleandbodyprops, as well ascontinue,previousandcancelfor navigation between tour steps.
Note that to use these custom components you need to define them in your Flows organization with the same properties and exit nodes as described above. For detailed instructions on building custom components, see the custom components documentation.
The <flows-slot> element lets you render Flows UI elements dynamically within your application. You can add placeholder UI for empty states. See app.html for an example.
Learn more about Flows and how to use its features in the official Flows documentation.
