Breeze 在奥雷利亚如何使用微风?

Breeze 在奥雷利亚如何使用微风?,breeze,aurelia,Breeze,Aurelia,我是aurelia的新手,我使用skeleton typescript aspnetcore skeleton项目来构建我的第一个应用程序。框架工作得很好,但是当我按照aurelia breeze插件指南将其集成到我的应用程序中时,我使用了 import breeze from 'breeze'; 在ts文件上,但出现错误:找不到模块“breeze”。我在谷歌上搜索了这么多,以至于有人提到d.ts文件丢失了,我将它从git()复制到typings文件夹,但是d.ts文件在第一行出现了另一个错误

我是aurelia的新手,我使用skeleton typescript aspnetcore skeleton项目来构建我的第一个应用程序。框架工作得很好,但是当我按照aurelia breeze插件指南将其集成到我的应用程序中时,我使用了

import breeze from 'breeze';
在ts文件上,但出现错误:找不到模块“breeze”。我在谷歌上搜索了这么多,以至于有人提到d.ts文件丢失了,我将它从git()复制到typings文件夹,但是d.ts文件在第一行出现了另一个错误,找不到模块“breeze client”:

import breeze from 'breeze-client';
我检查了nmp文件夹(wwwroot/nmp),aurelia breeze和breeze client都在那里,package.json中也一样

我将aurelia-breeze.d.ts与typings文件夹下的其他d.ts文件进行了比较, 这些文件都带有一个名为index.d.ts的框架,并带有一个typings.json用于标记


所以我想这个错误应该是由打字配置引起的,我在谷歌上搜索了很长时间,但是没有答案,你能告诉我如何使它工作吗?提前谢谢。

我在我的Aurelia应用程序中没有使用TypeScript,但我在集成breeze时遇到了同样的问题。最后,我解决了这个问题(或者说找到了这个解决方法),将它作为一个简单的脚本添加,而不是从node_模块(或者jspm_包,具体取决于您使用的是哪一个)加载它

这是我的新main.js文件:

export function configure(aurelia) {    
    aurelia.use
        .standardConfiguration()        
        .plugin('aurelia-knockout');

    return aurelia.start().then(() => {
        require(["../scripts/lib/breeze.debug"], function(breeze) {
            require([
                "../scripts/lib/breeze.savequeuing",
            ], function(savequeuing){
                aurelia.setRoot();
            });             
        });                     
    });    
}
希望这有帮助。在我的例子中,我甚至在加载了breeze本身之后集成了breeze的breeze.savequeuing插件。不过,可能有更好的方法来做到这一点

还要注意,我使用“require”作为模块加载器。我使用了Aurelia CLI,因此我在Aurelia.json文件的“build”下设置了它,如下所示:

"loader": {
      "type": "require",
      "configTarget": "vendor-bundle.js",
      "includeBundleMetadataInConfig": "auto",
      "config": {
        "waitSeconds": 0,
        "paths": {
          "jquery": "../scripts/lib/cdn/jquery-3.1.0.min",
          "knockout": "../scripts/lib/knockout-3.4.0"          
        }
      },
....
}
     {
        "name": "vendor-bundle.js",
        "prepend": [
          "node_modules/bluebird/js/browser/bluebird.core.js",          
          "scripts/lib/require.js"
        ],
 ...
}
在“bundles”下面,如下所示:

"loader": {
      "type": "require",
      "configTarget": "vendor-bundle.js",
      "includeBundleMetadataInConfig": "auto",
      "config": {
        "waitSeconds": 0,
        "paths": {
          "jquery": "../scripts/lib/cdn/jquery-3.1.0.min",
          "knockout": "../scripts/lib/knockout-3.4.0"          
        }
      },
....
}
     {
        "name": "vendor-bundle.js",
        "prepend": [
          "node_modules/bluebird/js/browser/bluebird.core.js",          
          "scripts/lib/require.js"
        ],
 ...
}

我没有在我的Aurelia应用程序中使用TypeScript,但我在集成breeze时遇到了同样的问题。最后,我解决了这个问题(或者说找到了这个解决方法),将它作为一个简单的脚本添加,而不是从node_模块(或者jspm_包,具体取决于您使用的是哪一个)加载它

这是我的新main.js文件:

export function configure(aurelia) {    
    aurelia.use
        .standardConfiguration()        
        .plugin('aurelia-knockout');

    return aurelia.start().then(() => {
        require(["../scripts/lib/breeze.debug"], function(breeze) {
            require([
                "../scripts/lib/breeze.savequeuing",
            ], function(savequeuing){
                aurelia.setRoot();
            });             
        });                     
    });    
}
希望这有帮助。在我的例子中,我甚至在加载了breeze本身之后集成了breeze的breeze.savequeuing插件。不过,可能有更好的方法来做到这一点

还要注意,我使用“require”作为模块加载器。我使用了Aurelia CLI,因此我在Aurelia.json文件的“build”下设置了它,如下所示:

"loader": {
      "type": "require",
      "configTarget": "vendor-bundle.js",
      "includeBundleMetadataInConfig": "auto",
      "config": {
        "waitSeconds": 0,
        "paths": {
          "jquery": "../scripts/lib/cdn/jquery-3.1.0.min",
          "knockout": "../scripts/lib/knockout-3.4.0"          
        }
      },
....
}
     {
        "name": "vendor-bundle.js",
        "prepend": [
          "node_modules/bluebird/js/browser/bluebird.core.js",          
          "scripts/lib/require.js"
        ],
 ...
}
在“bundles”下面,如下所示:

"loader": {
      "type": "require",
      "configTarget": "vendor-bundle.js",
      "includeBundleMetadataInConfig": "auto",
      "config": {
        "waitSeconds": 0,
        "paths": {
          "jquery": "../scripts/lib/cdn/jquery-3.1.0.min",
          "knockout": "../scripts/lib/knockout-3.4.0"          
        }
      },
....
}
     {
        "name": "vendor-bundle.js",
        "prepend": [
          "node_modules/bluebird/js/browser/bluebird.core.js",          
          "scripts/lib/require.js"
        ],
 ...
}

要将breezejs客户端与aurelia一起使用,必须执行以下操作

  • 安装所需的软件包
  • 在模块加载器上配置依赖项

    在我的例子中,我将amd与requirejs一起使用,因此依赖项如下

  • (下面包括requirejs config.js文件和aurelia.json完整文件)

  • 根据需要导入并初始化TypeScript项目上的库
  • 完成了!!你现在可以使用微风了。i、 e
  • (来自布莱恩·诺伊斯的优秀课程)

    PS:我将发布我的requirejs config.js文件的全部内容,以及用于aurelia cli构建的aurelia.json,查看并注意前置、预加载和垫片

    //-------------------config.js----------------------------------------------
        require.config(
          {
            baseUrl: 'src',
            paths: {
        
              pipelines: 'resources/pipelines',
              templates: 'resources/templates',
              interceptors: 'resources/interceptors',
        
              bluebird: '../node_modules/bluebird/js/browser/bluebird.min',
              bootstrap: '../node_modules/bootstrap/dist/js/bootstrap.min',
        
              "aurelia-animator-css": '../node_modules/aurelia-animator-css/dist/amd/aurelia-animator-css',
              "aurelia-binding": '../node_modules/aurelia-binding/dist/amd/aurelia-binding',
              "aurelia-bootstrapper": '../node_modules/aurelia-bootstrapper/dist/amd/aurelia-bootstrapper',
              "aurelia-breeze": '../node_modules/aurelia-breeze/dist/amd/aurelia-breeze',
              "aurelia-computed": '../node_modules/aurelia-computed/dist/amd/aurelia-computed',
              "aurelia-dependency-injection": '../node_modules/aurelia-dependency-injection/dist/amd/aurelia-dependency-injection',
              "aurelia-event-aggregator": '../node_modules/aurelia-event-aggregator/dist/amd/aurelia-event-aggregator',
              "aurelia-fetch-client": '../node_modules/aurelia-fetch-client/dist/amd/aurelia-fetch-client',
              "aurelia-framework": '../node_modules/aurelia-framework/dist/amd/aurelia-framework',
              "aurelia-history": '../node_modules/aurelia-history/dist/amd/aurelia-history',
              "aurelia-history-browser": '../node_modules/aurelia-history-browser/dist/amd/aurelia-history-browser',
              "aurelia-http-client": '../node_modules/aurelia-http-client/dist/amd/aurelia-http-client',
              "aurelia-loader": '../node_modules/aurelia-loader/dist/amd/aurelia-loader',
              "aurelia-loader-default": '../node_modules/aurelia-loader-default/dist/amd/aurelia-loader-default',
              "aurelia-logging": '../node_modules/aurelia-logging/dist/amd/aurelia-logging',
              "aurelia-logging-console": '../node_modules/aurelia-logging-console/dist/amd/aurelia-logging-console',
              "aurelia-metadata": '../node_modules/aurelia-metadata/dist/amd/aurelia-metadata',
              "aurelia-pal": '../node_modules/aurelia-pal/dist/amd/aurelia-pal',
              "aurelia-pal-browser": '../node_modules/aurelia-pal-browser/dist/amd/aurelia-pal-browser',
              "aurelia-path": '../node_modules/aurelia-path/dist/amd/aurelia-path',
              "aurelia-polyfills": '../node_modules/aurelia-polyfills/dist/amd/aurelia-polyfills',
              "aurelia-router": '../node_modules/aurelia-router/dist/amd/aurelia-router',
              "aurelia-route-recognizer": '../node_modules/aurelia-route-recognizer/dist/amd/aurelia-route-recognizer',
              "aurelia-task-queue": '../node_modules/aurelia-task-queue/dist/amd/aurelia-task-queue',
              "aurelia-templating": '../node_modules/aurelia-templating/dist/amd/aurelia-templating',
              "aurelia-templating-binding": '../node_modules/aurelia-templating-binding/dist/amd/aurelia-templating-binding',
        
              "breeze-client": '../node_modules/breeze-client/breeze.base.min',
              "breeze.modelLibrary": '../node_modules/breeze-client/breeze.modelLibrary.backingStore',
              "breeze.dataService": '../node_modules/breeze-client/breeze.dataService.webApi',
              "breeze.uriBuilder": '../node_modules/breeze-client/breeze.uriBuilder.json',
        
              jquery: '../node_modules/jquery/dist/jquery.min',
              lodash: '../node_modules/lodash/lodash.min',
              moment: '../node_modules/moment/min/moment-with-locales.min',
              numeral: '../node_modules/numeral/min/numeral.min',
              pouchdb: '../node_modules/pouchdb/dist/pouchdb.min',
              text: '../node_modules/text/text',
              toastr: '../node_modules/toastr/build/toastr.min',
        
              "jquery-ui": '../node_modules/jquery-ui/dist/jquery-ui.min'
        
            },
            packages: [
              {
                name: 'aurelia-dialog',
                location: '../node_modules/aurelia-dialog/dist/amd',
                main: 'aurelia-dialog'
              },
              {
                name: 'aurelia-templating-resources',
                location: '../node_modules/aurelia-templating-resources/dist/amd',
                main: 'aurelia-templating-resources'
              },
              {
                name: 'aurelia-templating-router',
                location: '../node_modules/aurelia-templating-router/dist/amd',
                main: 'aurelia-templating-router'
              },
              {
                name: 'aurelia-testing',
                location: '../node_modules/aurelia-testing/dist/amd',
                main: 'aurelia-testing'
              },
              {
                name: 'aurelia-validation',
                location: '../node_modules/aurelia-validation/dist/amd',
                main: 'aurelia-validation'
              },
              {
                name: 'popper.js',
                location: '../node_modules/popper.js/dist/umd/',
                main: 'popper.min'
              }
            ],
            shim: {
              'aurelia-breeze': {
                exports: 'BreezeObjectObserver',
                deps: ['breeze-client', 'breeze.modelLibrary', 'breeze.dataService', 'breeze.uriBuilder']
              },
              'breeze-client': {
                exports: 'breeze'
              },
              bootstrap: {
                exports: '$.fn.button',
                deps: ['jquery', 'popper.js']
              },
              jquery: {
                exports: '$'
              },
              "jquery-ui": {
                exports: '$.autocomplete',
                deps: ['jquery']
              },
              lodash: {
                exports: '_'
              },
              "popper.js": {
                exports: 'Popper'
              },
              toastr: {
                deps: ['jquery']
              }
        
            }
          });
        
        require(['aurelia-bootstrapper']);
    
    //-------------------aurelia.json----------------------------------------------
        {
          "name": "mgame",
          "type": "project:application",
          "bundler": {
            "id": "cli",
            "displayName": "Aurelia-CLI"
          },
          "platform": {
            "id": "aspnetcore",
            "displayName": "ASP.NET Core",
            "index": "index.html",
            "baseDir": ".",
            "output": "dist"
          },
          "transpiler": {
            "id": "typescript",
            "displayName": "TypeScript",
            "fileExtension": ".ts",
            "dtsSource": [ "./custom_typings/**/*.d.ts" ],
            "source": "src/**/*.ts"
          },
          "markupProcessor": {
            "id": "maximum",
            "displayName": "Maximum Minification",
            "fileExtension": ".html",
            "source": "src/**/*.html"
          },
          "cssProcessor": {
            "id": "sass",
            "displayName": "Sass",
            "fileExtension": ".scss",
            "source": "src/**/*.scss"
          },
          "editor": {
            "id": "visualstudio",
            "displayName": "Visual Studio"
          },
          "testFramework": {
            "id": "jasmine",
            "displayName": "Jasmine"
          },
          "unitTestRunner": {
            "id": "karma",
            "displayName": "Karma",
            "source": "test/unit/**/*.ts"
          },
          "e2eTestRunner": {
            "id": "protractor",
            "displayName": "Protractor",
            "source": "test/e2e/src/**/*.ts",
            "dist": "test/e2e/dist/",
            "typingsSource": [ "node_modules//@types/**/*.d.ts", "custom_typings/**/*.d.ts" ]
          },
          "paths": {
            "root": "src",
            "resources": "resources",
            "elements": "resources/elements",
            "pipelines": "resources/pipelines",
            "templates": "resources/templates",
            "attributes": "resources/attributes",
            "interceptors": "resources/interceptors",
            "valueConverters": "resources/converters",
            "bindingBehaviors": "resources/behaviors",
            "assets": [
              {
                "src": "node_modules/jquery-ui/dist/images/*",
                "dest": "/../images"
              },
              {
                "src": "node_modules/font-awesome/css/font-awesome.min.css",
                "dest": "/css"
              },
              {
                "src": "node_modules/font-awesome/fonts/*",
                "dest": "/fonts"
              }
            ]
          },
          "build": {
            "targets": [
              {
                "id": "aspnetcore",
                "displayName": "ASP.NET Core",
                "index": "index.html",
                "baseDir": ".",
                "output": "dist"
              }
            ],
            "loader": {
              "type": "require",
              "configTarget": "vendor-bundle.js",
              "includeBundleMetadataInConfig": "auto",
              "plugins": [
                {
                  "name": "text",
                  "extensions": [
                    ".html",
                    ".css"
                  ],
                  "stub": true
                }
              ]
            },
            "options": {
              "minify": "stage & prod",
              "sourcemaps": "dev & stage"
            },
            "bundles": [
              {
                "name": "app-bundle.js",
                "source": [
                  "[**/*.js]",
                  "**/*.{css,html}"
                ]
              },
              {
                "name": "vendor-bundle.js",
                "prepend": [
                  "node_modules/bluebird/js/browser/bluebird.min.js",
                  "node_modules/popper.js/dist/umd/popper.min.js",
                  "node_modules/requirejs/require.js"
                ],
                "dependencies": [
                  "jquery",
                  "lodash",
                  "moment",
                  "numeral",
                  "text",
                  {
                    "name": "aurelia-animator-css",
                    "path": "../node_modules/aurelia-animator-css/dist/amd",
                    "main": "aurelia-animator-css"
                  },
                  {
                    "name": "aurelia-binding",
                    "path": "../node_modules/aurelia-binding/dist/amd",
                    "main": "aurelia-binding"
                  },
                  {
                    "name": "aurelia-bootstrapper",
                    "path": "../node_modules/aurelia-bootstrapper/dist/amd",
                    "main": "aurelia-bootstrapper"
                  },
                  {
                    "name": "aurelia-breeze",
                    "path": "../node_modules/aurelia-breeze/dist/amd",
                    "main": "aurelia-breeze",
                    "exports": "BreezeObjectObserver",
                    "deps": [ "breeze-client", "breeze.modelLibrary", "breeze.dataService", "breeze.uriBuilder" ]
                  },
                  {
                    "name": "aurelia-computed",
                    "path": "../node_modules/aurelia-computed/dist/amd",
                    "main": "aurelia-computed"
                  },
                  {
                    "name": "aurelia-dependency-injection",
                    "path": "../node_modules/aurelia-dependency-injection/dist/amd",
                    "main": "aurelia-dependency-injection"
                  },
                  {
                    "name": "aurelia-dialog",
                    "path": "../node_modules/aurelia-dialog/dist/amd",
                    "main": "aurelia-dialog"
                  },
                  {
                    "name": "aurelia-event-aggregator",
                    "path": "../node_modules/aurelia-event-aggregator/dist/amd",
                    "main": "aurelia-event-aggregator"
                  },
                  {
                    "name": "aurelia-fetch-client",
                    "path": "../node_modules/aurelia-fetch-client/dist/amd",
                    "main": "aurelia-fetch-client"
                  },
                  {
                    "name": "aurelia-framework",
                    "path": "../node_modules/aurelia-framework/dist/amd",
                    "main": "aurelia-framework"
                  },
                  {
                    "name": "aurelia-history",
                    "path": "../node_modules/aurelia-history/dist/amd",
                    "main": "aurelia-history"
                  },
                  {
                    "name": "aurelia-history-browser",
                    "path": "../node_modules/aurelia-history-browser/dist/amd",
                    "main": "aurelia-history-browser"
                  },
                  {
                    "name": "aurelia-http-client",
                    "path": "../node_modules/aurelia-http-client/dist/amd",
                    "main": "aurelia-http-client"
                  },
                  {
                    "name": "aurelia-loader",
                    "path": "../node_modules/aurelia-loader/dist/amd",
                    "main": "aurelia-loader"
                  },
                  {
                    "name": "aurelia-loader-default",
                    "path": "../node_modules/aurelia-loader-default/dist/amd",
                    "main": "aurelia-loader-default"
                  },
                  {
                    "name": "aurelia-logging",
                    "path": "../node_modules/aurelia-logging/dist/amd",
                    "main": "aurelia-logging"
                  },
                  {
                    "name": "aurelia-logging-console",
                    "path": "../node_modules/aurelia-logging-console/dist/amd",
                    "main": "aurelia-logging-console"
                  },
                  {
                    "name": "aurelia-metadata",
                    "path": "../node_modules/aurelia-metadata/dist/amd",
                    "main": "aurelia-metadata"
                  },
                  {
                    "name": "aurelia-pal",
                    "path": "../node_modules/aurelia-pal/dist/amd",
                    "main": "aurelia-pal"
                  },
                  {
                    "name": "aurelia-pal-browser",
                    "path": "../node_modules/aurelia-pal-browser/dist/amd",
                    "main": "aurelia-pal-browser"
                  },
                  {
                    "name": "aurelia-path",
                    "path": "../node_modules/aurelia-path/dist/amd",
                    "main": "aurelia-path"
                  },
                  {
                    "name": "aurelia-polyfills",
                    "path": "../node_modules/aurelia-polyfills/dist/amd",
                    "main": "aurelia-polyfills"
                  },
                  {
                    "name": "aurelia-router",
                    "path": "../node_modules/aurelia-router/dist/amd",
                    "main": "aurelia-router"
                  },
                  {
                    "name": "aurelia-route-recognizer",
                    "path": "../node_modules/aurelia-route-recognizer/dist/amd",
                    "main": "aurelia-route-recognizer"
                  },
                  {
                    "name": "aurelia-task-queue",
                    "path": "../node_modules/aurelia-task-queue/dist/amd",
                    "main": "aurelia-task-queue"
                  },
                  {
                    "name": "aurelia-templating",
                    "path": "../node_modules/aurelia-templating/dist/amd",
                    "main": "aurelia-templating"
                  },
                  {
                    "name": "aurelia-templating-binding",
                    "path": "../node_modules/aurelia-templating-binding/dist/amd",
                    "main": "aurelia-templating-binding"
                  },
                  {
                    "name": "aurelia-templating-resources",
                    "path": "../node_modules/aurelia-templating-resources/dist/amd",
                    "main": "aurelia-templating-resources"
                  },
                  {
                    "name": "aurelia-templating-router",
                    "path": "../node_modules/aurelia-templating-router/dist/amd",
                    "main": "aurelia-templating-router"
                  },
                  {
                    "name": "aurelia-testing",
                    "path": "../node_modules/aurelia-testing/dist/amd",
                    "main": "aurelia-testing",
                    "env": "dev"
                  },
                  {
                    "name": "aurelia-validation",
                    "path": "../node_modules/aurelia-validation/dist/amd",
                    "main": "aurelia-validation"
                  },
                  {
                    "name": "bluebird",
                    "path": "../node_modules/bluebird/js/browser",
                    "main": "bluebird.min"
                  },
                  {
                    "name": "bootstrap",
                    "path": "../node_modules/bootstrap/dist",
                    "main": "js/bootstrap.min",
                    "deps": [ "jquery", "popper.js" ],
                    "exports": "$.fn.button",
                    "resources": [
                      "css/bootstrap.min.css"
                    ]
                  },
                  {
                    "name": "breeze-client",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.base.min",
                    "exports": "breeze"
                  },
                  {
                    "name": "breeze.modelLibrary",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.modelLibrary.backingStore"
                  },
                  {
                    "name": "breeze.dataService",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.dataService.webApi"
                  },
                  {
                    "name": "breeze.uriBuilder",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.uriBuilder.json"
                  },
                  {
                    "name": "jquery-ui",
                    "path": "../node_modules/jquery-ui/dist",
                    "main": "jquery-ui.min",
                    "deps": [ "jquery" ],
                    "exports": "$.autocomplete",
                    "resources": [ "jquery-ui.min.css" ]
                  },
                  {
                    "name": "popper.js",
                    "path": "../node_modules/popper.js/dist/umd",
                    "main": "popper.min",
                    "exports": "Popper"
                  },
                  {
                    "name": "pouchdb",
                    "path": "../node_modules/pouchdb/dist",
                    "main": "pouchdb.min"
                  },
                  {
                    "name": "toastr",
                    "path": "../node_modules/toastr",
                    "main": "toastr",
                    "deps": [ "jquery" ],
                    "resources": [ "build/toastr.min.css" ]
                  }
                ]
              }
            ]
          }
        }
    

    要将breezejs客户端与aurelia一起使用,必须执行以下操作

  • 安装所需的软件包
  • 在模块加载器上配置依赖项

    在我的例子中,我将amd与requirejs一起使用,因此依赖项如下

  • (下面包括requirejs config.js文件和aurelia.json完整文件)

  • 根据需要导入并初始化TypeScript项目上的库
  • 完成了!!你现在可以使用微风了。i、 e
  • (来自布莱恩·诺伊斯的优秀课程)

    PS:我将发布我的requirejs config.js文件的全部内容,以及用于aurelia cli构建的aurelia.json,查看并注意前置、预加载和垫片

    //-------------------config.js----------------------------------------------
        require.config(
          {
            baseUrl: 'src',
            paths: {
        
              pipelines: 'resources/pipelines',
              templates: 'resources/templates',
              interceptors: 'resources/interceptors',
        
              bluebird: '../node_modules/bluebird/js/browser/bluebird.min',
              bootstrap: '../node_modules/bootstrap/dist/js/bootstrap.min',
        
              "aurelia-animator-css": '../node_modules/aurelia-animator-css/dist/amd/aurelia-animator-css',
              "aurelia-binding": '../node_modules/aurelia-binding/dist/amd/aurelia-binding',
              "aurelia-bootstrapper": '../node_modules/aurelia-bootstrapper/dist/amd/aurelia-bootstrapper',
              "aurelia-breeze": '../node_modules/aurelia-breeze/dist/amd/aurelia-breeze',
              "aurelia-computed": '../node_modules/aurelia-computed/dist/amd/aurelia-computed',
              "aurelia-dependency-injection": '../node_modules/aurelia-dependency-injection/dist/amd/aurelia-dependency-injection',
              "aurelia-event-aggregator": '../node_modules/aurelia-event-aggregator/dist/amd/aurelia-event-aggregator',
              "aurelia-fetch-client": '../node_modules/aurelia-fetch-client/dist/amd/aurelia-fetch-client',
              "aurelia-framework": '../node_modules/aurelia-framework/dist/amd/aurelia-framework',
              "aurelia-history": '../node_modules/aurelia-history/dist/amd/aurelia-history',
              "aurelia-history-browser": '../node_modules/aurelia-history-browser/dist/amd/aurelia-history-browser',
              "aurelia-http-client": '../node_modules/aurelia-http-client/dist/amd/aurelia-http-client',
              "aurelia-loader": '../node_modules/aurelia-loader/dist/amd/aurelia-loader',
              "aurelia-loader-default": '../node_modules/aurelia-loader-default/dist/amd/aurelia-loader-default',
              "aurelia-logging": '../node_modules/aurelia-logging/dist/amd/aurelia-logging',
              "aurelia-logging-console": '../node_modules/aurelia-logging-console/dist/amd/aurelia-logging-console',
              "aurelia-metadata": '../node_modules/aurelia-metadata/dist/amd/aurelia-metadata',
              "aurelia-pal": '../node_modules/aurelia-pal/dist/amd/aurelia-pal',
              "aurelia-pal-browser": '../node_modules/aurelia-pal-browser/dist/amd/aurelia-pal-browser',
              "aurelia-path": '../node_modules/aurelia-path/dist/amd/aurelia-path',
              "aurelia-polyfills": '../node_modules/aurelia-polyfills/dist/amd/aurelia-polyfills',
              "aurelia-router": '../node_modules/aurelia-router/dist/amd/aurelia-router',
              "aurelia-route-recognizer": '../node_modules/aurelia-route-recognizer/dist/amd/aurelia-route-recognizer',
              "aurelia-task-queue": '../node_modules/aurelia-task-queue/dist/amd/aurelia-task-queue',
              "aurelia-templating": '../node_modules/aurelia-templating/dist/amd/aurelia-templating',
              "aurelia-templating-binding": '../node_modules/aurelia-templating-binding/dist/amd/aurelia-templating-binding',
        
              "breeze-client": '../node_modules/breeze-client/breeze.base.min',
              "breeze.modelLibrary": '../node_modules/breeze-client/breeze.modelLibrary.backingStore',
              "breeze.dataService": '../node_modules/breeze-client/breeze.dataService.webApi',
              "breeze.uriBuilder": '../node_modules/breeze-client/breeze.uriBuilder.json',
        
              jquery: '../node_modules/jquery/dist/jquery.min',
              lodash: '../node_modules/lodash/lodash.min',
              moment: '../node_modules/moment/min/moment-with-locales.min',
              numeral: '../node_modules/numeral/min/numeral.min',
              pouchdb: '../node_modules/pouchdb/dist/pouchdb.min',
              text: '../node_modules/text/text',
              toastr: '../node_modules/toastr/build/toastr.min',
        
              "jquery-ui": '../node_modules/jquery-ui/dist/jquery-ui.min'
        
            },
            packages: [
              {
                name: 'aurelia-dialog',
                location: '../node_modules/aurelia-dialog/dist/amd',
                main: 'aurelia-dialog'
              },
              {
                name: 'aurelia-templating-resources',
                location: '../node_modules/aurelia-templating-resources/dist/amd',
                main: 'aurelia-templating-resources'
              },
              {
                name: 'aurelia-templating-router',
                location: '../node_modules/aurelia-templating-router/dist/amd',
                main: 'aurelia-templating-router'
              },
              {
                name: 'aurelia-testing',
                location: '../node_modules/aurelia-testing/dist/amd',
                main: 'aurelia-testing'
              },
              {
                name: 'aurelia-validation',
                location: '../node_modules/aurelia-validation/dist/amd',
                main: 'aurelia-validation'
              },
              {
                name: 'popper.js',
                location: '../node_modules/popper.js/dist/umd/',
                main: 'popper.min'
              }
            ],
            shim: {
              'aurelia-breeze': {
                exports: 'BreezeObjectObserver',
                deps: ['breeze-client', 'breeze.modelLibrary', 'breeze.dataService', 'breeze.uriBuilder']
              },
              'breeze-client': {
                exports: 'breeze'
              },
              bootstrap: {
                exports: '$.fn.button',
                deps: ['jquery', 'popper.js']
              },
              jquery: {
                exports: '$'
              },
              "jquery-ui": {
                exports: '$.autocomplete',
                deps: ['jquery']
              },
              lodash: {
                exports: '_'
              },
              "popper.js": {
                exports: 'Popper'
              },
              toastr: {
                deps: ['jquery']
              }
        
            }
          });
        
        require(['aurelia-bootstrapper']);
    
    //-------------------aurelia.json----------------------------------------------
        {
          "name": "mgame",
          "type": "project:application",
          "bundler": {
            "id": "cli",
            "displayName": "Aurelia-CLI"
          },
          "platform": {
            "id": "aspnetcore",
            "displayName": "ASP.NET Core",
            "index": "index.html",
            "baseDir": ".",
            "output": "dist"
          },
          "transpiler": {
            "id": "typescript",
            "displayName": "TypeScript",
            "fileExtension": ".ts",
            "dtsSource": [ "./custom_typings/**/*.d.ts" ],
            "source": "src/**/*.ts"
          },
          "markupProcessor": {
            "id": "maximum",
            "displayName": "Maximum Minification",
            "fileExtension": ".html",
            "source": "src/**/*.html"
          },
          "cssProcessor": {
            "id": "sass",
            "displayName": "Sass",
            "fileExtension": ".scss",
            "source": "src/**/*.scss"
          },
          "editor": {
            "id": "visualstudio",
            "displayName": "Visual Studio"
          },
          "testFramework": {
            "id": "jasmine",
            "displayName": "Jasmine"
          },
          "unitTestRunner": {
            "id": "karma",
            "displayName": "Karma",
            "source": "test/unit/**/*.ts"
          },
          "e2eTestRunner": {
            "id": "protractor",
            "displayName": "Protractor",
            "source": "test/e2e/src/**/*.ts",
            "dist": "test/e2e/dist/",
            "typingsSource": [ "node_modules//@types/**/*.d.ts", "custom_typings/**/*.d.ts" ]
          },
          "paths": {
            "root": "src",
            "resources": "resources",
            "elements": "resources/elements",
            "pipelines": "resources/pipelines",
            "templates": "resources/templates",
            "attributes": "resources/attributes",
            "interceptors": "resources/interceptors",
            "valueConverters": "resources/converters",
            "bindingBehaviors": "resources/behaviors",
            "assets": [
              {
                "src": "node_modules/jquery-ui/dist/images/*",
                "dest": "/../images"
              },
              {
                "src": "node_modules/font-awesome/css/font-awesome.min.css",
                "dest": "/css"
              },
              {
                "src": "node_modules/font-awesome/fonts/*",
                "dest": "/fonts"
              }
            ]
          },
          "build": {
            "targets": [
              {
                "id": "aspnetcore",
                "displayName": "ASP.NET Core",
                "index": "index.html",
                "baseDir": ".",
                "output": "dist"
              }
            ],
            "loader": {
              "type": "require",
              "configTarget": "vendor-bundle.js",
              "includeBundleMetadataInConfig": "auto",
              "plugins": [
                {
                  "name": "text",
                  "extensions": [
                    ".html",
                    ".css"
                  ],
                  "stub": true
                }
              ]
            },
            "options": {
              "minify": "stage & prod",
              "sourcemaps": "dev & stage"
            },
            "bundles": [
              {
                "name": "app-bundle.js",
                "source": [
                  "[**/*.js]",
                  "**/*.{css,html}"
                ]
              },
              {
                "name": "vendor-bundle.js",
                "prepend": [
                  "node_modules/bluebird/js/browser/bluebird.min.js",
                  "node_modules/popper.js/dist/umd/popper.min.js",
                  "node_modules/requirejs/require.js"
                ],
                "dependencies": [
                  "jquery",
                  "lodash",
                  "moment",
                  "numeral",
                  "text",
                  {
                    "name": "aurelia-animator-css",
                    "path": "../node_modules/aurelia-animator-css/dist/amd",
                    "main": "aurelia-animator-css"
                  },
                  {
                    "name": "aurelia-binding",
                    "path": "../node_modules/aurelia-binding/dist/amd",
                    "main": "aurelia-binding"
                  },
                  {
                    "name": "aurelia-bootstrapper",
                    "path": "../node_modules/aurelia-bootstrapper/dist/amd",
                    "main": "aurelia-bootstrapper"
                  },
                  {
                    "name": "aurelia-breeze",
                    "path": "../node_modules/aurelia-breeze/dist/amd",
                    "main": "aurelia-breeze",
                    "exports": "BreezeObjectObserver",
                    "deps": [ "breeze-client", "breeze.modelLibrary", "breeze.dataService", "breeze.uriBuilder" ]
                  },
                  {
                    "name": "aurelia-computed",
                    "path": "../node_modules/aurelia-computed/dist/amd",
                    "main": "aurelia-computed"
                  },
                  {
                    "name": "aurelia-dependency-injection",
                    "path": "../node_modules/aurelia-dependency-injection/dist/amd",
                    "main": "aurelia-dependency-injection"
                  },
                  {
                    "name": "aurelia-dialog",
                    "path": "../node_modules/aurelia-dialog/dist/amd",
                    "main": "aurelia-dialog"
                  },
                  {
                    "name": "aurelia-event-aggregator",
                    "path": "../node_modules/aurelia-event-aggregator/dist/amd",
                    "main": "aurelia-event-aggregator"
                  },
                  {
                    "name": "aurelia-fetch-client",
                    "path": "../node_modules/aurelia-fetch-client/dist/amd",
                    "main": "aurelia-fetch-client"
                  },
                  {
                    "name": "aurelia-framework",
                    "path": "../node_modules/aurelia-framework/dist/amd",
                    "main": "aurelia-framework"
                  },
                  {
                    "name": "aurelia-history",
                    "path": "../node_modules/aurelia-history/dist/amd",
                    "main": "aurelia-history"
                  },
                  {
                    "name": "aurelia-history-browser",
                    "path": "../node_modules/aurelia-history-browser/dist/amd",
                    "main": "aurelia-history-browser"
                  },
                  {
                    "name": "aurelia-http-client",
                    "path": "../node_modules/aurelia-http-client/dist/amd",
                    "main": "aurelia-http-client"
                  },
                  {
                    "name": "aurelia-loader",
                    "path": "../node_modules/aurelia-loader/dist/amd",
                    "main": "aurelia-loader"
                  },
                  {
                    "name": "aurelia-loader-default",
                    "path": "../node_modules/aurelia-loader-default/dist/amd",
                    "main": "aurelia-loader-default"
                  },
                  {
                    "name": "aurelia-logging",
                    "path": "../node_modules/aurelia-logging/dist/amd",
                    "main": "aurelia-logging"
                  },
                  {
                    "name": "aurelia-logging-console",
                    "path": "../node_modules/aurelia-logging-console/dist/amd",
                    "main": "aurelia-logging-console"
                  },
                  {
                    "name": "aurelia-metadata",
                    "path": "../node_modules/aurelia-metadata/dist/amd",
                    "main": "aurelia-metadata"
                  },
                  {
                    "name": "aurelia-pal",
                    "path": "../node_modules/aurelia-pal/dist/amd",
                    "main": "aurelia-pal"
                  },
                  {
                    "name": "aurelia-pal-browser",
                    "path": "../node_modules/aurelia-pal-browser/dist/amd",
                    "main": "aurelia-pal-browser"
                  },
                  {
                    "name": "aurelia-path",
                    "path": "../node_modules/aurelia-path/dist/amd",
                    "main": "aurelia-path"
                  },
                  {
                    "name": "aurelia-polyfills",
                    "path": "../node_modules/aurelia-polyfills/dist/amd",
                    "main": "aurelia-polyfills"
                  },
                  {
                    "name": "aurelia-router",
                    "path": "../node_modules/aurelia-router/dist/amd",
                    "main": "aurelia-router"
                  },
                  {
                    "name": "aurelia-route-recognizer",
                    "path": "../node_modules/aurelia-route-recognizer/dist/amd",
                    "main": "aurelia-route-recognizer"
                  },
                  {
                    "name": "aurelia-task-queue",
                    "path": "../node_modules/aurelia-task-queue/dist/amd",
                    "main": "aurelia-task-queue"
                  },
                  {
                    "name": "aurelia-templating",
                    "path": "../node_modules/aurelia-templating/dist/amd",
                    "main": "aurelia-templating"
                  },
                  {
                    "name": "aurelia-templating-binding",
                    "path": "../node_modules/aurelia-templating-binding/dist/amd",
                    "main": "aurelia-templating-binding"
                  },
                  {
                    "name": "aurelia-templating-resources",
                    "path": "../node_modules/aurelia-templating-resources/dist/amd",
                    "main": "aurelia-templating-resources"
                  },
                  {
                    "name": "aurelia-templating-router",
                    "path": "../node_modules/aurelia-templating-router/dist/amd",
                    "main": "aurelia-templating-router"
                  },
                  {
                    "name": "aurelia-testing",
                    "path": "../node_modules/aurelia-testing/dist/amd",
                    "main": "aurelia-testing",
                    "env": "dev"
                  },
                  {
                    "name": "aurelia-validation",
                    "path": "../node_modules/aurelia-validation/dist/amd",
                    "main": "aurelia-validation"
                  },
                  {
                    "name": "bluebird",
                    "path": "../node_modules/bluebird/js/browser",
                    "main": "bluebird.min"
                  },
                  {
                    "name": "bootstrap",
                    "path": "../node_modules/bootstrap/dist",
                    "main": "js/bootstrap.min",
                    "deps": [ "jquery", "popper.js" ],
                    "exports": "$.fn.button",
                    "resources": [
                      "css/bootstrap.min.css"
                    ]
                  },
                  {
                    "name": "breeze-client",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.base.min",
                    "exports": "breeze"
                  },
                  {
                    "name": "breeze.modelLibrary",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.modelLibrary.backingStore"
                  },
                  {
                    "name": "breeze.dataService",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.dataService.webApi"
                  },
                  {
                    "name": "breeze.uriBuilder",
                    "path": "../node_modules/breeze-client",
                    "main": "breeze.uriBuilder.json"
                  },
                  {
                    "name": "jquery-ui",
                    "path": "../node_modules/jquery-ui/dist",
                    "main": "jquery-ui.min",
                    "deps": [ "jquery" ],
                    "exports": "$.autocomplete",
                    "resources": [ "jquery-ui.min.css" ]
                  },
                  {
                    "name": "popper.js",
                    "path": "../node_modules/popper.js/dist/umd",
                    "main": "popper.min",
                    "exports": "Popper"
                  },
                  {
                    "name": "pouchdb",
                    "path": "../node_modules/pouchdb/dist",
                    "main": "pouchdb.min"
                  },
                  {
                    "name": "toastr",
                    "path": "../node_modules/toastr",
                    "main": "toastr",
                    "deps": [ "jquery" ],
                    "resources": [ "build/toastr.min.css" ]
                  }
                ]
              }
            ]
          }
        }