Skip to content

Commit

Permalink
Add Object.hasOwn polyfill
Browse files Browse the repository at this point in the history
  • Loading branch information
Cohee1207 committed Dec 10, 2023
1 parent f43d738 commit 2e6ab8b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
<link rel="apple-touch-icon" sizes="72x72" href="img/apple-icon-72x72.png" />
<link rel="apple-touch-icon" sizes="114x114" href="img/apple-icon-114x114.png" />
<link rel="apple-touch-icon" sizes="144x144" href="img/apple-icon-144x144.png" />
<script src="lib/object-hasown.js"></script>
<script src="lib/jquery-3.5.1.min.js"></script>
<script src="lib/jquery-ui.min.js"></script>
<script src="lib/jquery.transit.min.js"></script>
Expand Down
4 changes: 4 additions & 0 deletions public/lib/object-hasown.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
// Polyfill for old Safari versions
if (!Object.hasOwn) {
Object.hasOwn = function (obj, prop) { return obj.hasOwnProperty(prop); }
}

0 comments on commit 2e6ab8b

Please sign in to comment.