aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/pages
diff options
context:
space:
mode:
Diffstat (limited to 'packages/website/ts/pages')
-rw-r--r--packages/website/ts/pages/documentation/source_link.tsx9
1 files changed, 6 insertions, 3 deletions
diff --git a/packages/website/ts/pages/documentation/source_link.tsx b/packages/website/ts/pages/documentation/source_link.tsx
index 2fb69e2f0..08d372743 100644
--- a/packages/website/ts/pages/documentation/source_link.tsx
+++ b/packages/website/ts/pages/documentation/source_link.tsx
@@ -8,10 +8,13 @@ interface SourceLinkProps {
version: string;
}
+const SUB_PKG = '0x.js';
+
export function SourceLink(props: SourceLinkProps) {
- const source = props.source;
- const githubUrl = constants.GITHUB_0X_JS_URL;
- const sourceCodeUrl = `${githubUrl}/blob/v${props.version}/${source.fileName}#L${source.line}`;
+ const src = props.source;
+ const url = constants.GITHUB_0X_JS_URL;
+ // https://github.com/0xProject/0x.js/blob/0x.js%400.26.1/packages/0x.js/src/contract_wrappers/exchange_wrapper.ts
+ const sourceCodeUrl = `${url}/blob/${SUB_PKG}%40${props.version}/packages/${SUB_PKG}/${src.fileName}#L${src.line}`;
return (
<div className="pt2" style={{fontSize: 14}}>
<a