Skip to content
This repository has been archived by the owner on Oct 26, 2021. It is now read-only.

WIP: Add link to documentation #33

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/components/sandbox/sandbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,14 @@ function renderOperatorLabel(label) {
fontWeight: '400',
fontSize: `${fontSize}rem`
};
return h('span.operatorLabel', {style}, label);
let docLinkStyle = {
fontSize: `0.8rem`,
display: 'block',
marginTop: '5px'
};
let operatorName = label.split('(')[0].toLowerCase();
let href = `https://github.com/Reactive-Extensions/RxJS/blob/master/doc/api/core/operators/${operatorName}.md`;
Copy link

@Kisty Kisty Sep 30, 2016

Choose a reason for hiding this comment

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

Copy link

Choose a reason for hiding this comment

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

Would broaden the documentation to other languages. Also, there's information and links to different languages. e.g. http://reactivex.io/documentation/operators/debounce.html

Copy link
Author

Choose a reason for hiding this comment

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

Just need to all the operators map to reactivex.io. Maybe an effort could be made to duplicated this for xstream and rxjs5.

Copy link

Choose a reason for hiding this comment

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

Ah, don't all operators map to the generic documentation?

return [h('span.operatorLabel', {style}, label), h('a', {style: docLinkStyle, href}, `See Documentation`)];
}

function renderOperator(label) {
Expand Down