Skip to content

Commit

Permalink
Merge pull request jupyterlab#6840 from AlokTakshak/issue-6788
Browse files Browse the repository at this point in the history
Added key
  • Loading branch information
ian-r-rose authored Jul 22, 2019
2 parents 0aa41d1 + 5fd521e commit 9a69476
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions packages/extensionmanager/src/companions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export function presentCompanions(
let entries = [];
if (serverCompanion) {
entries.push(
<p>
<p key="server-companion">
This package has indicated that it needs a corresponding server
extension:
<code> {serverCompanion.base.name!}</code>
Expand All @@ -117,28 +117,28 @@ export function presentCompanions(
}
if (kernelCompanions.length > 0) {
entries.push(
<p>
<p key={'kernel-companion'}>
This package has indicated that it needs a corresponding package for the
kernel.
</p>
);
for (let entry of kernelCompanions) {
for (let [index, entry] of kernelCompanions.entries()) {
entries.push(
<p>
<p key={`companion-${index}`}>
The package
<code>{entry.kernelInfo.base.name!}</code>, is required by the
following kernels:
</p>
);
let kernelEntries = [];
for (let kernel of entry.kernels) {
for (let [index, kernel] of entry.kernels.entries()) {
kernelEntries.push(
<li>
<li key={`kernels-${index}`}>
<code>{kernel.display_name}</code>
</li>
);
}
entries.push(<ul>{kernelEntries}</ul>);
entries.push(<ul key={'kernel-companion-end'}>{kernelEntries}</ul>);
}
}
let body = (
Expand Down

0 comments on commit 9a69476

Please sign in to comment.