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: img import from /docs/assets to /website/static/docs/assets #2681

Closed
wants to merge 4 commits into from
Closed

Conversation

khali70
Copy link
Contributor

@khali70 khali70 commented Jul 9, 2021

@facebook-github-bot
Copy link

Hi @khali70!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at [email protected]. Thanks!

@khali70
Copy link
Contributor Author

khali70 commented Jul 9, 2021

future work

adding trouble shooting advice

adding advice to use react-native doctor in order to check if react-native environment is setup correctly

@netlify
Copy link

netlify bot commented Jul 9, 2021

✔️ Deploy Preview for react-native ready!

🔨 Explore the source changes: 55f0810

🔍 Inspect the deploy log: https://app.netlify.com/sites/react-native/deploys/60ed4e811acb490007615861

😎 Browse the preview: https://deploy-preview-2681--react-native.netlify.app

@facebook-github-bot
Copy link

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks!

Copy link
Collaborator

@Simek Simek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @khali70, can you elaborate more on your issue? Can you provide link to the page, your browser information etc.?

It looks like the image you are trying to change URL to image which currently works correctly on PROD, in both next nad 0.64 docs (https://reactnative.dev/docs/environment-setup):

Screenshot 2021-07-10 094843

Also the reason why the deploy failed are incorrect image links after the changes:

4:56:58 PM: Error: Image static/website/static/img/AndroidAVDConfiguration.png used in ../docs/_getting-started-linux-android.md not found.
4:56:58 PM:     at async Promise.all (index 0)
4:56:58 PM: Error: Image static/website/static/img/AndroidAVDConfiguration.png used in ../docs/_getting-started-macos-android.md not found.
4:56:58 PM:     at async Promise.all (index 1)
4:56:58 PM: Error: Image static/website/static/img/AndroidAVDConfiguration.png used in ../docs/_getting-started-windows-android.md not found.
4:56:58 PM:     at async Promise.all (index 0)
4:56:58 PM: Client bundle compiled with errors therefore further build is impossible.
4:56:58 PM: error Command failed with exit code 1.

You can read more about how to Docusaurus handles assets in the docs:

@khali70
Copy link
Contributor Author

khali70 commented Jul 13, 2021

as far as i understand

the imgs need to move from

GettingStartedAndroidStudioAVD.png not found at /website/static/docs/assets

# move or copy img from
- /website/static/img/AndroidAVDConfiguration.png
# to 
+ /website/docs/assets/GettingStartedAndroidStudioAVD.png

Screenshot from 2021-07-13 10-42-15

@khali70 khali70 requested a review from Simek July 13, 2021 08:35
@Simek
Copy link
Collaborator

Simek commented Jul 13, 2021

@khali70 Thank you for the information in the edited portion of the issue. 👍

Unfortunately those pages should not be accessible, those are a partial pages, which content is used in the configuration wizard located at https://reactnative.dev/docs/environment-setup. On this page images are displayed correctly, at least on my machine.

I have already reported this issue to the Docusaurus team during the site migration. Hope they will be able to fix this issue soon. CC @slorber

I will later take a look if this problem can be solved somehow on our side, for example by adding redirects to the server.

@khali70 khali70 closed this Jul 13, 2021
@slorber
Copy link
Contributor

slorber commented Jul 15, 2021

Will be fixed by facebook/docusaurus#5173

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants