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

Live view to js #616

Closed
wants to merge 2 commits into from
Closed

Live view to js #616

wants to merge 2 commits into from

Conversation

rexemtoxa
Copy link
Collaborator

No description provided.

@rexemtoxa rexemtoxa requested a review from vtm9 January 27, 2020 20:45
const diffMinutes = Math.floor((diffInMiliseconds/1000/60));
const diffSeconds = Math.floor(((diffInMiliseconds/1000/60 - diffMinutes)*60));

p.innerHTML = `Will start in ${diffMinutes} minutes ${diffSeconds} seconds`;
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I have some doubts about inner html.. I don't know..is it right way?

Copy link
Contributor

Choose a reason for hiding this comment

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

p.innerHTML = 'the tournament has begun';
clearInterval(intervalId);
};
}, 1000);
Copy link
Contributor

Choose a reason for hiding this comment

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

Што-то как-то труднее стало)) Как насчет вынести в реакт компонент и повесить его на p#timer?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

вот вопрос с inner html и отпал) спасибо)

Copy link
Contributor

Choose a reason for hiding this comment

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

да, надо просто реакт компенент сделать. можно либку использовать, или самому data-attr заюзать

@vtm9
Copy link
Contributor

vtm9 commented Apr 4, 2020

sorry, man

@vtm9 vtm9 closed this Apr 4, 2020
@vtm9 vtm9 deleted the live_view_to_js branch September 12, 2020 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants