Skip to content

Instantly share code, notes, and snippets.

import sublime, sublime_plugin, os, re
class FileNameComplete(sublime_plugin.EventListener):
def on_query_completions(self, view, prefix, locations):
completions = []
sel = view.sel()[0].a
if "string" in view.syntax_name(sel):
pass
@asika32764
asika32764 / URI.js
Last active August 29, 2015 14:04
The simple JS URI object. Repository move to https://github.com/asika32764/SimpleURI.js
/*!
* The simple JS URI object.
*
* @license GNU General Public License version 2 or later; see LICENSE
* @link https://gist.github.com/asika32764/6556efdf5c593ce140bb
*/
/**
* The simple JS URI object.
*
@Rplus
Rplus / URL.js
Last active August 29, 2015 14:07 — forked from jlong/uri.js
var url = "http://example.com:3000/pathname/?search=test#hash";
var _a = new URL(url);
_a.protocol; // => "http:"
_a.hostname; // => "example.com"
_a.port; // => "3000"
_a.pathname; // => "/pathname/"
_a.search; // => "?search=test"
_a.hash; // => "#hash"