react-native-PDFView icon indicating copy to clipboard operation
react-native-PDFView copied to clipboard

Support for new architecture

Open tarkcelk opened this issue 2 years ago • 4 comments

Describe the bug Pdf package doesn't work when build a project with new architecture enabled, need to update the package to be compatible.

To Reproduce

  • Create a react native project with latest version (My case was 0.71.4)
  • Enable the new architecture.
  • Install this package and build the project.
  • Render a pdf and see the fabric incompatibility warning.

Steps to reproduce the behavior:

  1. Render PDF with any kind of resource.
  2. See the fabric incompatibility warning

Expected behavior Proper rendering when new architecture is enabled.

Screenshots Screenshot_1679408336

Smartphone (please complete the following information):

  • Device: Pixel 2 , iPhone 13
  • OS: Android, iOS
  • Version API 29, iOS 16.0

tarkcelk avatar Mar 21 '23 16:03 tarkcelk

Hi @tarkcelk, new new architecture is still experimental, right?

This documentation is still experimental and details are subject to changes as we iterate.

rumax avatar Mar 27 '23 09:03 rumax

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar May 15 '23 07:05 stale[bot]

Now you can use the "New Renderer Interop Layer" The interop layer is shipped with React Native 0.72

Just add a component name like this in react-native.config.js

module.exports = { project:{ android: { unstable_reactLegacyComponentNames: [ "PDFView" ] }, ios: { unstable_reactLegacyComponentNames: [ "PDFView" ] } }, };

"The interop layer is a feature that lets you reuse legacy Native Components in New Architecture apps"

Read More https://github.com/reactwg/react-native-new-architecture/discussions/135

mrshahzeb7 avatar Oct 02 '23 11:10 mrshahzeb7

@mrshahzeb7 thanks, i will be looking to that

tarkcelk avatar Nov 24 '23 15:11 tarkcelk