Skip to content

Commit 714700c

Browse files
author
Ives van Hoorne
committed
Create sitemap
1 parent 492c5f9 commit 714700c

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

public/sitemap.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
3+
<url>
4+
<loc>https://codesandbox.io/</loc>
5+
<changefreq>daily</changefreq>
6+
<priority>1.0</priority>
7+
</url>
8+
</urlset>

src/app/pages/SandboxView/Sandbox/Editor/Workspace/Dependencies/index.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,11 @@ export default class Dependencies extends React.PureComponent {
4949
this.setState({
5050
processing: true,
5151
});
52-
await sandboxActions.addNPMDependency(sandboxId, realName, realVersion);
52+
try {
53+
await sandboxActions.addNPMDependency(sandboxId, realName, realVersion);
54+
} catch (e) {
55+
console.error(e);
56+
}
5357
this.setState({
5458
processing: false,
5559
});
@@ -60,7 +64,11 @@ export default class Dependencies extends React.PureComponent {
6064
this.setState({
6165
processing: true,
6266
});
63-
await sandboxActions.removeNPMDependency(sandboxId, name);
67+
try {
68+
await sandboxActions.removeNPMDependency(sandboxId, name);
69+
} catch (e) {
70+
console.error(e);
71+
}
6472
this.setState({
6573
processing: false,
6674
});

0 commit comments

Comments
 (0)