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(docs): compilation issues when building production files #412

Merged
merged 2 commits into from
Aug 30, 2019

Conversation

bpas247
Copy link
Member

@bpas247 bpas247 commented Aug 30, 2019

This was due to ownerDocument using document when it wasn't
defined (which is the case when building production files).

This was due to `ownerDocument` using `document` when it wasn't
defined (which is the case when building production files).
@@ -2,6 +2,7 @@ import ownerDocument from 'dom-helpers/ownerDocument';
import { useState, useEffect } from 'react';

const resolveRef = ref => {
if(typeof document === 'undefined') return undefined;
Copy link
Member Author

Choose a reason for hiding this comment

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

So I'm pretty sure returning undefined here isn't the correct behavior for this use case, does anyone have a better suggestion for what to return here?

@bpas247 bpas247 added the bug label Aug 30, 2019
@bpas247 bpas247 merged commit 3867655 into master Aug 30, 2019
@bpas247 bpas247 deleted the fix/docs-not-building branch August 30, 2019 19:28
@bpas247 bpas247 mentioned this pull request Aug 31, 2019
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.

2 participants