Skip to content

Commit

Permalink
v1.4.0 Support Vue Component Files
Browse files Browse the repository at this point in the history
  • Loading branch information
Hirse committed Aug 25, 2017
1 parent 6f90f96 commit 8d81f59
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 20 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ All notable changes to this project will be documented in this file.
This project tries to adhere to [Semantic Versioning](http://semver.org/).


## 1.4.0 - 2017-08-25
### Added
- Support for Vue Component Files using HTML mode (see [#98](https://github.com/Hirse/brackets-outline-list/issues/98))


## 1.3.1 - 2017-08-25
### Fixed
- Support Python default parameter floats (see [#97](https://github.com/Hirse/brackets-outline-list/issues/97))
Expand Down
37 changes: 19 additions & 18 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,24 +20,25 @@ define(function (require, exports, module) {

/* beautify preserve:start *//* eslint-disable key-spacing */
var languageMapping = {
JavaScript: "JavaScript",
JSX: "JavaScript",
Haxe: "Haxe",
CoffeeScript: "CoffeeScript",
CSS: "CSS",
SCSS: "CSS",
LESS: "CSS",
Stylus: "Stylus",
PHP: "PHP",
Ruby: "Ruby",
Python: "Python",
Markdown: "Markdown",
"Markdown (GitHub)": "Markdown",
XML: "XML",
HTML: "XML",
"Embedded Ruby": "XML",
SVG: "XML",
Jade: "Jade"
JavaScript: "JavaScript",
JSX: "JavaScript",
Haxe: "Haxe",
CoffeeScript: "CoffeeScript",
CSS: "CSS",
SCSS: "CSS",
LESS: "CSS",
Stylus: "Stylus",
PHP: "PHP",
Ruby: "Ruby",
Python: "Python",
Markdown: "Markdown",
"Markdown (GitHub)": "Markdown",
XML: "XML",
HTML: "XML",
"Embedded Ruby": "XML",
SVG: "XML",
"Vue component file": "XML",
Jade: "Jade"
};
/* eslint-enable key-spacing *//* beautify preserve:end */

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "hirse.outline-list",
"version": "1.3.1",
"version": "1.4.0",
"title": "Brackets Outline List",
"description": "Displays a list of the functions or definitions in the currently opened document. Works with CSS, CoffeeScript, HTML, Haxe, Jade, JavaScript, JSX, LESS, Markdown, PHP, Python, Ruby, SCSS, SVG, Stylus, and XML.",
"engines": {
Expand Down Expand Up @@ -40,7 +40,7 @@
"pl"
],
"package-i18n": {
"ar":{
"ar": {
"description": " CSS, CoffeeScript, HTML, Haxe, Jade, JavaScript, JSX, LESS, Markdown, PHP, Python, Ruby, SCSS, SVG, Stylus, and XML.يعرض قائم بالوظائف أو التعريفات في الوثيقة المفتوحة حاليا ، يعمل مع لغة"
},
"de": {
Expand Down
27 changes: 27 additions & 0 deletions test/XMLSpec.js
Original file line number Diff line number Diff line change
Expand Up @@ -149,5 +149,32 @@ define(function XMLSpec(require) {
done();
});
});


it("detects html in vue", function (done) {
var test = require("text!example/html/vue.vue");
Parser.parse(test).then(function (result) {
expect(result).toEqual([
{
name: "template",
namespace: "",
level: 0,
id: "",
class: [],
line: 1,
ch: 0
}, {
name: "div",
namespace: "",
level: 1,
id: "",
class: [],
line: 2,
ch: 4
}
]);
done();
});
});
});
});
4 changes: 4 additions & 0 deletions test/example/html/vue.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<!-- my-component.vue -->
<template>
<div>This will be pre-compiled</div>
</template>

0 comments on commit 8d81f59

Please sign in to comment.