Upgraded Vue.js sample to GA. (#168)
This commit is contained in:
parent
fb66482027
commit
4a4fccf69b
|
@ -1,7 +1,5 @@
|
||||||
|
// Place your settings in this file to overwrite default and user settings.
|
||||||
{
|
{
|
||||||
"vsicons.presets.angular": false,
|
"tslint.configFile": "./config/tslint.json",
|
||||||
"typescript.tsdk": "./node_modules/typescript/lib",
|
"tslint.ignoreDefinitionFiles": true
|
||||||
"files.associations": {
|
|
||||||
"*.vue": "vue"
|
|
||||||
}
|
|
||||||
}
|
}
|
|
@ -5,7 +5,7 @@
|
||||||
Sample Todo web part demonstrating how you can utilize [Vue](https://vuejs.org/v2) (a progressive framework for building user interfaces) with SharePoint Framework using handy [single-file components](https://vuejs.org/v2/guide/single-file-components.html) approach.
|
Sample Todo web part demonstrating how you can utilize [Vue](https://vuejs.org/v2) (a progressive framework for building user interfaces) with SharePoint Framework using handy [single-file components](https://vuejs.org/v2/guide/single-file-components.html) approach.
|
||||||
|
|
||||||
## Used SharePoint Framework Version
|
## Used SharePoint Framework Version
|
||||||
![drop](https://img.shields.io/badge/drop-RC0-green.svg)
|
![drop](https://img.shields.io/badge/drop-GA-green.svg)
|
||||||
|
|
||||||
## Applies to
|
## Applies to
|
||||||
|
|
||||||
|
@ -23,6 +23,7 @@ vuejs-todo-single-file-component|Sergei Sergeev ([@sergeev_srg](https://twitter.
|
||||||
Version|Date|Comments
|
Version|Date|Comments
|
||||||
-------|----|--------
|
-------|----|--------
|
||||||
0.0.1|January 27, 2017|Initial version.
|
0.0.1|January 27, 2017|Initial version.
|
||||||
|
0.0.2|March 30, 2017|Updated to GA
|
||||||
|
|
||||||
## Disclaimer
|
## Disclaimer
|
||||||
**THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**
|
**THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**
|
||||||
|
|
|
@ -1,15 +1,15 @@
|
||||||
{
|
{
|
||||||
"entries": [
|
"entries": [
|
||||||
{
|
{
|
||||||
"entry": "./lib/webparts/todo/TodoWebPart.js",
|
"entry": "./lib/webparts/toDo/ToDoWebPart.js",
|
||||||
"manifest": "./src/webparts/todo/TodoWebPart.manifest.json",
|
"manifest": "./src/webparts/toDo/ToDoWebPart.manifest.json",
|
||||||
"outputPath": "./dist/todo.bundle.js"
|
"outputPath": "./dist/to-do.bundle.js"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"externals": {
|
"externals": {
|
||||||
"vue": "node_modules/vue/dist/vue.runtime.js"
|
"vue": "node_modules/vue/dist/vue.runtime.js"
|
||||||
},
|
},
|
||||||
"localizedResources": {
|
"localizedResources": {
|
||||||
"todoStrings": "webparts/todo/loc/{locale}.js"
|
"toDoStrings": "webparts/toDo/loc/{locale}.js"
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"solution": {
|
"solution": {
|
||||||
"name": "vue-todo-client-side-solution",
|
"name": "vue-todo-client-side-solution",
|
||||||
"id": "3a3be1f4-edfd-4816-8cfb-f100f1727031",
|
"id": "93e1bc8f-a063-4617-aa40-837e3b39f958",
|
||||||
"version": "1.0.0.0"
|
"version": "1.0.0.0"
|
||||||
},
|
},
|
||||||
"paths": {
|
"paths": {
|
||||||
|
|
|
@ -16,13 +16,11 @@
|
||||||
"export-name": false,
|
"export-name": false,
|
||||||
"forin": false,
|
"forin": false,
|
||||||
"label-position": false,
|
"label-position": false,
|
||||||
"label-undefined": false,
|
|
||||||
"member-access": true,
|
"member-access": true,
|
||||||
"no-arg": false,
|
"no-arg": false,
|
||||||
"no-console": false,
|
"no-console": false,
|
||||||
"no-construct": false,
|
"no-construct": false,
|
||||||
"no-duplicate-case": true,
|
"no-duplicate-case": true,
|
||||||
"no-duplicate-key": false,
|
|
||||||
"no-duplicate-variable": true,
|
"no-duplicate-variable": true,
|
||||||
"no-eval": false,
|
"no-eval": false,
|
||||||
"no-function-expression": true,
|
"no-function-expression": true,
|
||||||
|
@ -32,8 +30,6 @@
|
||||||
"no-unnecessary-semicolons": true,
|
"no-unnecessary-semicolons": true,
|
||||||
"no-unused-expression": true,
|
"no-unused-expression": true,
|
||||||
"no-unused-imports": true,
|
"no-unused-imports": true,
|
||||||
"no-unused-variable": true,
|
|
||||||
"no-unreachable": true,
|
|
||||||
"no-use-before-declare": true,
|
"no-use-before-declare": true,
|
||||||
"no-with-statement": true,
|
"no-with-statement": true,
|
||||||
"semicolon": true,
|
"semicolon": true,
|
||||||
|
@ -44,7 +40,7 @@
|
||||||
"valid-typeof": true,
|
"valid-typeof": true,
|
||||||
"variable-name": false,
|
"variable-name": false,
|
||||||
"whitespace": false,
|
"whitespace": false,
|
||||||
"prefer-const": true
|
"prefer-const": false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,33 +1,33 @@
|
||||||
{
|
{
|
||||||
"name": "vue-todo",
|
"name": "vue-todo",
|
||||||
"version": "0.0.1",
|
"version": "0.0.2",
|
||||||
"private": true,
|
"private": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=0.10.0"
|
"node": ">=0.10.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@microsoft/sp-client-base": "~0.7.0",
|
"@microsoft/sp-client-base": "~1.0.0",
|
||||||
"@microsoft/sp-client-preview": "~0.9.0",
|
"@microsoft/sp-core-library": "~1.0.0",
|
||||||
"@microsoft/sp-core-library": "~0.1.2",
|
"@microsoft/sp-webpart-base": "~1.0.0",
|
||||||
"@microsoft/sp-webpart-base": "~0.4.0",
|
|
||||||
"@types/webpack-env": ">=1.12.1 <1.14.0",
|
"@types/webpack-env": ">=1.12.1 <1.14.0",
|
||||||
"vue": "^2.1.10",
|
"vue": "^2.2.6",
|
||||||
"vue-class-component": "^4.4.0",
|
"vue-class-component": "^5.0.1",
|
||||||
"vue-property-decorator": "^3.4.0",
|
"vue-property-decorator": "^4.0.0",
|
||||||
"vue-template-compiler": "^2.1.10"
|
"vue-template-compiler": "^2.2.6"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@microsoft/sp-build-web": "~0.9.0",
|
"@microsoft/gulp-core-build-typescript": "^3.0.0",
|
||||||
"@microsoft/sp-module-interfaces": "~0.7.0",
|
"@microsoft/sp-build-web": "~1.0.0",
|
||||||
"@microsoft/sp-webpart-workbench": "~0.8.0",
|
"@microsoft/sp-module-interfaces": "~1.0.0",
|
||||||
|
"@microsoft/sp-webpart-workbench": "~1.0.0",
|
||||||
"@types/chai": ">=3.4.34 <3.6.0",
|
"@types/chai": ">=3.4.34 <3.6.0",
|
||||||
"@types/mocha": ">=2.2.33 <2.6.0",
|
"@types/mocha": ">=2.2.33 <2.6.0",
|
||||||
|
"css-loader": "^0.28.0",
|
||||||
"gulp": "~3.9.1",
|
"gulp": "~3.9.1",
|
||||||
"node-sass": "^4.3.0",
|
"node-sass": "^4.5.2",
|
||||||
"sass-loader": "^4.1.1",
|
"sass-loader": "^6.0.3",
|
||||||
"css-loader": "^0.26.1",
|
"vue-loader": "^11.3.4",
|
||||||
"vue-loader": "^10.0.2",
|
"webpack-merge": "^4.1.0"
|
||||||
"webpack-merge": "^2.4.0"
|
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "gulp bundle",
|
"build": "gulp bundle",
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
var context = require.context('.', true, /.+\.test\.js?$/);
|
|
||||||
|
|
||||||
context.keys().forEach(context);
|
|
||||||
|
|
||||||
module.exports = context;
|
|
|
@ -1,16 +1,16 @@
|
||||||
{
|
{
|
||||||
"$schema": "../../../node_modules/@microsoft/sp-module-interfaces/lib/manifestSchemas/jsonSchemas/clientSideComponentManifestSchema.json",
|
"$schema": "../../../node_modules/@microsoft/sp-module-interfaces/lib/manifestSchemas/jsonSchemas/clientSideComponentManifestSchema.json",
|
||||||
|
|
||||||
"id": "1c993233-909a-4662-8643-8548d961f2b3",
|
"id": "a0e1eddd-ea67-4775-a52b-0141c5807146",
|
||||||
"alias": "TodoWebPart",
|
"alias": "ToDoWebPart",
|
||||||
"componentType": "WebPart",
|
"componentType": "WebPart",
|
||||||
"version": "0.0.1",
|
"version": "0.0.1",
|
||||||
"manifestVersion": 2,
|
"manifestVersion": 2,
|
||||||
|
|
||||||
"preconfiguredEntries": [{
|
"preconfiguredEntries": [{
|
||||||
"groupId": "1c993233-909a-4662-8643-8548d961f2b3",
|
"groupId": "a0e1eddd-ea67-4775-a52b-0141c5807146",
|
||||||
"group": { "default": "Under Development" },
|
"group": { "default": "Under Development" },
|
||||||
"title": { "default": "Todo" },
|
"title": { "default": "ToDo" },
|
||||||
"description": { "default": "My Todo's" },
|
"description": { "default": "My Todo's" },
|
||||||
"officeFabricIconFontName": "Page",
|
"officeFabricIconFontName": "Page",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
|
|
@ -4,11 +4,12 @@ import {
|
||||||
IPropertyPaneConfiguration,
|
IPropertyPaneConfiguration,
|
||||||
PropertyPaneTextField
|
PropertyPaneTextField
|
||||||
} from '@microsoft/sp-webpart-base';
|
} from '@microsoft/sp-webpart-base';
|
||||||
|
import { escape } from '@microsoft/sp-lodash-subset';
|
||||||
|
|
||||||
import * as Vue from 'vue';
|
import * as Vue from 'vue';
|
||||||
import TodoComponent from './components/todo/Todo.vue';
|
import TodoComponent from './components/todo/Todo.vue';
|
||||||
|
|
||||||
import * as strings from 'todoStrings';
|
import * as strings from 'toDoStrings';
|
||||||
import { ITodoWebPartProps } from './ITodoWebPartProps';
|
import { ITodoWebPartProps } from './ITodoWebPartProps';
|
||||||
|
|
||||||
export default class TodoWebPart extends BaseClientSideWebPart<ITodoWebPartProps> {
|
export default class TodoWebPart extends BaseClientSideWebPart<ITodoWebPartProps> {
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
declare interface ITodoStrings {
|
declare interface IToDoStrings {
|
||||||
PropertyPaneDescription: string;
|
PropertyPaneDescription: string;
|
||||||
BasicGroupName: string;
|
BasicGroupName: string;
|
||||||
DescriptionFieldLabel: string;
|
DescriptionFieldLabel: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
declare module 'todoStrings' {
|
declare module 'toDoStrings' {
|
||||||
const strings: ITodoStrings;
|
const strings: IToDoStrings;
|
||||||
export = strings;
|
export = strings;
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
import { assert } from 'chai';
|
import { assert } from 'chai';
|
||||||
|
|
||||||
describe('TodoWebPart', () => {
|
describe('ToDoWebPart', () => {
|
||||||
it('should do something', () => {
|
it('should do something', () => {
|
||||||
assert.ok(true);
|
assert.ok(true);
|
||||||
});
|
});
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
"declaration": true,
|
"declaration": true,
|
||||||
"sourceMap": true,
|
"sourceMap": true,
|
||||||
"experimentalDecorators": true,
|
"experimentalDecorators": true,
|
||||||
|
"allowSyntheticDefaultImports": true,
|
||||||
"types": [
|
"types": [
|
||||||
"webpack-env"
|
"webpack-env"
|
||||||
]
|
]
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
// Type definitions for Microsoft ODSP projects
|
||||||
|
// Project: ODSP
|
||||||
|
|
||||||
|
/* Global definition for UNIT_TEST builds
|
||||||
|
Code that is wrapped inside an if(UNIT_TEST) {...}
|
||||||
|
block will not be included in the final bundle when the
|
||||||
|
--ship flag is specified */
|
||||||
|
declare const UNIT_TEST: boolean;
|
|
@ -0,0 +1 @@
|
||||||
|
/// <reference path="@ms/odsp.d.ts" />
|
Loading…
Reference in New Issue