Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix autolinking / react-native.config.js #1931

Closed
asklar opened this issue Mar 21, 2021 · 4 comments
Closed

Fix autolinking / react-native.config.js #1931

asklar opened this issue Mar 21, 2021 · 4 comments

Comments

@asklar
Copy link
Collaborator

asklar commented Mar 21, 2021

Currently react-native.config.js is a bit messy, the file is at the root of the package yet it is really only about the example app.
The example should be put in its own separate package, and the root react-native.config.js should have the required package information so that autolinking can work on different platforms (e.g. Windows requires this after #1617).

The Windows portion of react-native.config.js for the main package requires this data:

module.exports = {
  dependency: {
    platforms: {
      windows: {
        sourceDir: 'windows',
        solutionFile: 'ReactNativeWebView.sln',
        projects: [
          {
            projectFile: 'ReactNativeWebView\\ReactNativeWebView.vcxproj',
            directDependency: true,
          },
          {
            projectFile: 'WebViewBridgeComponent\\WebViewBridgeComponent.vcxproj',
            directDependency: false,
          }
        ],
      },
    },
  },
};
@asklar
Copy link
Collaborator Author

asklar commented Mar 21, 2021

@chrisglein @chiaramooney FYI

@asklar
Copy link
Collaborator Author

asklar commented Mar 21, 2021

Should also update the docs: https://github.com/react-native-webview/react-native-webview/blob/master/docs/Getting-Started.md#windows

@github-actions
Copy link

Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically

@github-actions github-actions bot added the Stale label May 21, 2021
@asklar
Copy link
Collaborator Author

asklar commented May 21, 2021

@chiaramooney this should be fixed already right? Can you double check and close this if so?

@github-actions github-actions bot removed the Stale label May 22, 2021
@asklar asklar closed this as completed May 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant