Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
</head>
<body>
<base href="http://polygit.org/polymer+:master/components/">
<link href="polymer/polymer.html" rel="import">
  
<x-test></x-test>
  
<dom-module id="x-test">
  <template>
    <a id="tofocus" href="/">I'm going to get focused</a>
    <a>but I'm not</a>
  </template>
</dom-module>
  
</body>
</html>
 
Polymer({
  is: 'x-test',
  attached: function () {
    this.$.tofocus.focus();
  }
});
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers