react-dnd-test-backend

  • Version 16.0.1
  • Published
  • 12.9 kB
  • 1 dependency
  • MIT license

Install

npm i react-dnd-test-backend
yarn add react-dnd-test-backend
pnpm add react-dnd-test-backend

Overview

A mock backend for testing React DnD apps

Index

Variables

variable TestBackend

const TestBackend: BackendFactory;

    Classes

    class TestBackendImpl

    class TestBackendImpl implements Backend, ITestBackend {}

      constructor

      constructor(manager: DragDropManager, context: TestBackendContext);

        property context

        context: TestBackendContext;

          property didCallSetup

          didCallSetup: boolean;

            property didCallTeardown

            didCallTeardown: boolean;

              property manager

              manager: DragDropManager;

                method connectDragPreview

                connectDragPreview: () => Unsubscribe;

                  method connectDragSource

                  connectDragSource: () => Unsubscribe;

                    method connectDropTarget

                    connectDropTarget: () => Unsubscribe;

                      method profile

                      profile: () => Record<string, number>;

                        method setup

                        setup: () => void;

                          method simulateBeginDrag

                          simulateBeginDrag: (sourceIds: Identifier[], options: BeginDragOptions) => void;

                            method simulateDrop

                            simulateDrop: () => void;

                              method simulateEndDrag

                              simulateEndDrag: () => void;

                                method simulateHover

                                simulateHover: (targetIds: Identifier[], options: HoverOptions) => void;

                                  method simulatePublishDragSource

                                  simulatePublishDragSource: () => void;

                                    method teardown

                                    teardown: () => void;

                                      Interfaces

                                      interface ITestBackend

                                      interface ITestBackend extends Backend {}

                                        property didCallSetup

                                        didCallSetup: boolean;

                                          property didCallTeardown

                                          didCallTeardown: boolean;

                                            method simulateBeginDrag

                                            simulateBeginDrag: (sourceIds: Identifier[], options?: any) => void;

                                              method simulateDrop

                                              simulateDrop: () => void;

                                                method simulateEndDrag

                                                simulateEndDrag: () => void;

                                                  method simulateHover

                                                  simulateHover: (targetIds: Identifier[], options?: any) => void;

                                                    method simulatePublishDragSource

                                                    simulatePublishDragSource: () => void;

                                                      interface TestBackendContext

                                                      interface TestBackendContext {}

                                                        property document

                                                        document?: Document;

                                                          property window

                                                          window?: Window;

                                                            interface TestBackendOptions

                                                            interface TestBackendOptions {}

                                                              property onCreate

                                                              onCreate?: (be: ITestBackend) => void;

                                                                Package Files (3)

                                                                Dependencies (1)

                                                                Dev Dependencies (5)

                                                                Peer Dependencies (0)

                                                                No peer dependencies.

                                                                Badge

                                                                To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/react-dnd-test-backend.

                                                                • Markdown
                                                                  [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/react-dnd-test-backend)
                                                                • HTML
                                                                  <a href="https://www.jsdocs.io/package/react-dnd-test-backend"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>