<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>154458</bug_id>
          
          <creation_ts>2016-02-19 09:29:44 -0800</creation_ts>
          <short_desc>All DOM descriptors are completely useless</short_desc>
          <delta_ts>2016-02-19 19:14:51 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>DOM</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>140575</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Andrea Giammarchi">andrea.giammarchi</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>barraclough</cc>
    
    <cc>cdumez</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1166435</commentid>
    <comment_count>0</comment_count>
    <who name="Andrea Giammarchi">andrea.giammarchi</who>
    <bug_when>2016-02-19 09:29:44 -0800</bug_when>
    <thetext>It is currently basically impossible to patch or polyfill anything in the DOM world in WebKit.

For instance, writing this snippet produce an unexpected result:
```js
Object.getOwnPropertyDescriptor(Element.prototype, &apos;id&apos;);
{get: undefined, set: undefined, enumerable: true, configurable: false} = $1

```

Accessors are all flagged as non configurable, and the worst part is that it&apos;s not possible to use them with custom elements or any other sort of element because getters and setters are unreachable (being undefined).

This makes patching HTMLAnchorElement and URL impossible in a polyfill like the following one:
https://github.com/WebReflection/url-search-params#url-search-params

so my only option would be to eventually fully replace the whole URL object (also why is every constructor with a prototype an object instead of a function I don&apos;t get it) which is way more obtrusive approach.

Bear in mind that polyfill already works with many other browsers, but I&apos;ll just push a version that gives up on WebKit which is quite sad because I love this browser.

Thanks for considering fixing this.

Best Regards</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1166666</commentid>
    <comment_count>1</comment_count>
    <who name="Chris Dumez">cdumez</who>
    <bug_when>2016-02-19 19:14:51 -0800</bug_when>
    <thetext>This has been fixed in Bug 140575. It should work fine in a recent WebKit nightly build:
https://nightly.webkit.org

If issues remain, please let me know.

*** This bug has been marked as a duplicate of bug 140575 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>