Datasource Inline

Edit on GitHub

This document explains the Datasource Inline service in the Components Library.


Datasource Inline is an Angular Service that allows passing data along with the configuration of the Datasource.

Check out an example usage of the Datasource Inline.

Service configuration:

  • type—a datasource type.
  • data—a datasource data.
        type: 'inline',
        data: ['Inline 1', 'Inline 2'],

Service registration

Register the service:

declare module '@spryker/datasource' {
    interface DatasourceRegistry {
        inline: DatasourceInlineService;

    imports: [
            inline: DatasourceInlineService,
export class RootModule {}


Below you can find interfaces for the Datasource Inline:

export interface DatasourceInlineConfig extends DatasourceConfig {
    data: unknown;