Reactpy

Latest version: v1.1.0

Safety actively analyzes 688568 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 8 of 15

0.29.0

Contains breaking changes, the most significant of which are:

- Moves the runtime client build directory to a "user data" directory rather a directory
where IDOM's code was installed. This has the advantage of not requiring write
permissions to rebuild the client if IDOM was installed globally rather than in a
virtual environment.
- The custom JS component interface has been reworked to expose an API similar to
the `createElement`, `render`, `unmountComponentAtNode` functions from React.

**Issues Fixed:**

- 375
- 394
- 401

**Highlighted Commits:**

- add try/except around event handling - f2bf589
- do not call find_builtin_server_type at import time - e29745e
- import default from react/reactDOM/fast-json-patch - 74c8a34
- no named exports for react/reactDOM - f13bf35
- debug logs for runtime build dir create/update - af94f4e
- put runtime build in user data dir - 0af69d2
- change shared to update_on_change - 6c09a86
- rework js module interface + fix docs - 699cc66
- correctly serialize File object - a2398dc

0.28.0

Includes a wide variety of improvements:

- support `currentTime` attr of audio/video elements
- support for the `files` attribute from the target of input elements
- model children are passed to the Javascript `mount()` function
- began to add tests to client-side javascript
- add a `mountLayoutWithWebSocket` function to `idom-client-react`

and breaking changes, the most significant of which are:

- Refactor existing server implementations as functions adhering to a protocol. This greatly simplified much of the code responsible for setting up servers and avoids the use of inheritance.
- Switch to a monorepo-style structure for Javascript enabling a greater separation of concerns and common workspace scripts in `package.json`.
- Use a `loadImportSource()` function instead of trying to infer the path to dynamic modules which was brittle and inflexible. Allowing the specific client implementation to discover where "import sources" are located means `idom-client-react` doesn't need to try and devise a solution that will work for all cases. The fallout from this change is the addition of `importSource.sourceType` which, for the moment can either be `"NAME"` or `"URL"` where the former indicates the client is expected to know where to find a module of that name, and the latter should (usually) be passed on to `import()`

0.27.0

Introduces changes to the interface for custom Javascript components. This now allows JS modules to export a ``mount(element, component, props)`` function which can be used to bind new elements to the DOM instead of using the application's own React instance and specifying React as a peer dependency. This avoids a wide variety of potential issues with implementing custom components and opens up the possiblity for a wider variety of component implementations.

- modules with mount func should not have children - 94d006c
- limit to flask<2.0 - e7c11d0
- federate modules with mount function - bf63a62

0.26.0

A collection of minor fixes and changes that, as a whole, add up to something requiring a minor release. The most significant addition is a fix for situations where a `Layout` can raise an error when a component whose state has been delete is rendered. This occurs when element has been unmounted, but a latent event tells the layout it should be updated. For example, when a user clicks a button rapidly, and the resulting update deletes the original button.

- only one attr dict in vdom constructor - 555086a
- remove Option setter/getter with current property - 2627f79
- add cli command to show options - c9e6869
- check component has model state before render - 6a50d56
- rename daemon to run_in_thread + misc - 417b687

0.25.0

Completely refactors layout dispatchers by switching from a class-based approach to one that leverages pure functions. While the logic itself isn't any simpler, it was easier to implement, and now hopefully understand, correctly. This conversion was motivated by several bugs that had cropped up related to improper usage of ``anyio``.

**Issues Fixed:**

- 330
- 298

**Highlighted Commits:**

- improve docs + simplify multiview - 4129b60
- require anyio>=3.0 - 24aed28
- refactor dispatchers - ce8e060

0.24.0

This release contains an update that allows components and elements to have “identity”. That is, their state can be preserved across updates. Before this point, only the state for the component at the root of an update was preserved. Now though, the state for any component and element with a key that is unique amongst its siblings, will be preserved so long as this is also true for parent elements/components within the scope of the current update. Thus, only when the key of the element or component changes will its state do the same.

In a future update, the default key for all elements and components will be its index with respect to its siblings in the layout. The `IDOM_FEATURE_INDEX_AS_DEFAULT_KEY` feature flag has been introduced to allow users to enable this behavior early.

- add feature flag for default key behavior - 42ee01c
- use unique object instead of index as default key - 5727ab4
- make HookCatcher/StaticEventHandlers testing utils - 1abfd76
- add element and component identity - 5548f02
- minor doc updates - e5511d9
- add tests for callback identity preservation with keys - 72e03ec
- add 'key' to VDOM spec - c3236fe
- Rename validate_serialized_vdom to validate_vdom - d04faf9
- EventHandler should not serialize itself - f7a59f2
- fix docs typos - 42b2e20
- fixes: 331 - add roadmap to docs - 4226c12

Page 8 of 15

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.