Friday, December 13, 2019

New Tab As Apps Chrome Extension

Get This Extension

This extension was created in response to Chrome's Feb 2014 removal of the "Enable Instant Extended API" that let you default your new tab to the Apps view.

While installed, new tabs default to 'chrome://apps/'

Use the "Feedback" button at the top of this article if you want to ask any questions.

Updated Dec 2019 because it stopped working. Changed tab.url to tab.pendingUrl.

See also: Home Button At Top Right Chrome Extension which also lets you default new tabs to 'chrome://apps/'

manifest.json

{
  "manifest_version": 2,
  "name": "New Tab As Apps",
  "description": "Causes the new tab to default to the Apps view instead of the google splash view.",
  "version": "1.1",
  "permissions": ["tabs"],
  "background": { "scripts": ["background.js"] },
  "icons" : { "16": "icon16.png",
              "48": "icon48.png",
             "128": "icon128.png" }
}

background.js

chrome.tabs.onCreated.addListener(function(tab) {
  if (tab.pendingUrl == "chrome://newtab/")
  { chrome.tabs.update( tab.id , { 'url' : 'chrome://apps/' } ); }
});

I haven't tried it, but new tab with chrome apps looks like it has a better solution which looks like it doesn't require the tabs permission.

manifest.json
{
  "manifest_version": 2,
  "chrome_url_overrides": {"newtab": "redirect.html"}
}

redirect.html
<html>
  <script type="text/javascript" src="redirect.js"></script>
</html>

redirect.js
chrome.tabs.getCurrent( function(tab){
  chrome.tabs.update(tab.id, {url: "chrome://apps/"});
});
web
{ "url": "https:\/\/holtstrom.com\/michael\/", "base": "\/michael", "domain": "holtstrom.com", "loggedin": false, "avatar": "", "render": "nothing", "doTracking": true, "trackingID": "UA-36983794-1", "description": "", "tmdbUrl": "http:\/\/www.themoviedb.org\/", "tmdbPoster": "http:\/\/image.tmdb.org\/t\/p\/w342" }