storybook_device_preview 0.2.0+4
storybook_device_preview: ^0.2.0+4 copied to clipboard

A plugin for device_preview package that allows to embed storybook_flutter.

storybook_device_preview #

A plugin for device_preview package that allows to embed storybook_flutter with contents and knobs support.

Getting Started #

You can use CustomStorybook with builder parameter to embed the storybook into DevicePreview. Pass storybookPlugins to enable contents and knobs panel:

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) =>
      CustomStorybook(
        builder: (context) =>
            DevicePreview(
              plugins: storybookPlugins,
              builder: (context) =>
                  MaterialApp(
                    builder: DevicePreview.appBuilder,
                    locale: DevicePreview.locale(context),
                    home: const Scaffold(body: CurrentStory()),
                  ),
            ),
        children: [
          // Your stories go here
        ],
      );
}

Features and bugs #

Please file feature requests and bugs at the issue tracker.

7
likes
70
pub points
69%
popularity

Publisher

ookamikb.dev

A plugin for device_preview package that allows to embed storybook_flutter.

Repository (GitHub)
View/report issues

License

BSD-2-Clause (LICENSE)

Dependencies

device_preview, flutter, storybook_flutter

More

Packages that depend on storybook_device_preview