-
Notifications
You must be signed in to change notification settings - Fork 176
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jonathan Casarrubias
committed
Sep 30, 2016
1 parent
8609c7e
commit a6ecd9d
Showing
70 changed files
with
1,039 additions
and
380 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// Place your settings in this file to overwrite default and user settings. | ||
{ | ||
"typescript.tsdk": "node_modules/typescript/lib" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,17 @@ | ||
Copyright (c) 2016 Jonathan Casarrubias <@johncasarrubias> | ||
#Art and Graphics License | ||
Copyright (c) 2016 MEAN Expert - Jonathan Casarrubias <@johncasarrubias> | ||
|
||
All Rights Reserved | ||
|
||
MEAN Expert, LoopBack SDK Builder, SDK Builder Mascot and The FireLoop.io name and Logos are protected by copyright and distributed under licenses restricting copying, distribution and decompilation. | ||
|
||
#Software MTI License | ||
Copyright (c) 2016 MEAN Expert - Jonathan Casarrubias <@johncasarrubias> | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
|
||
[MIT License](http://opensource.org/licenses/MIT) | ||
[MIT License](http://opensource.org/licenses/MIT) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
/* tslint:disable */ | ||
var SocketIO = require('nativescript-socket.io'); | ||
var SocketIO = require('nativescript-socketio'); | ||
export class SocketDriver { | ||
static connect(url: any, options: any) { | ||
return SocketIO.connect(url, options); | ||
let socketIO: any = new SocketIO(url, options) | ||
socketIO.connect(); | ||
return socketIO; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,69 @@ | ||
/** | ||
* @module SDK Index | ||
* @module SDKModule | ||
* @author Jonathan Casarrubias <t:@johncasarrubias> <gh:jonathan-casarrubias> | ||
* @license MTI 2016 Jonathan Casarrubias | ||
* @description | ||
* The SDK Index is automatically built by the LoopBack SDK Builder. | ||
* The SDKModule is a generated Software Development Kit automatically built by | ||
* the LoopBack SDK Builder open source module. | ||
* | ||
* The SDK Index will temporally keep providing access to everything in the SDK | ||
* including services. This is because will maintain backwards compatibility for those | ||
* Applications below Angular 2 RC 5 version that does not support NgModule just yet. | ||
* The SDKModule provides Angular 2 >= RC.5 support, which means that NgModules | ||
* can import this Software Development Kit as follows: | ||
* | ||
* IMPORTANT NOTE: | ||
* | ||
* If your application is equal or above RC 5 It is recommended to import the SDK | ||
* Module located in ./sdk.module.ts and follow the instructions. | ||
* APP Route Module Context | ||
* ============================================================================ | ||
* import { NgModule } from '@angular/core'; | ||
* import { BrowserModule } from '@angular/platform-browser'; | ||
* // App Root | ||
* import { AppComponent } from './app.component'; | ||
* // Feature Modules | ||
* import { SDKModule } from './shared/sdk/sdk.module'; | ||
* // Import Routing | ||
* import { routing } from './app.routing'; | ||
* @NgModule({ | ||
* imports: [ | ||
* BrowserModule, | ||
* routing, | ||
* SDKModule.forRoot() | ||
* ], | ||
* declarations: [ AppComponent ], | ||
* bootstrap: [ AppComponent ] | ||
* }) | ||
* export class AppModule { } | ||
* | ||
* Also, It is recommended for you to start upgrading your application in order to | ||
* support NgModules before backwards support is also dropped by Angular. | ||
* | ||
* READ: https://angular.io/docs/ts/latest/cookbook/rc4-to-rc5.html#!#5-cleanup | ||
**/ | ||
<%- buildModuleImports(models, true) %> | ||
/** | ||
* IMPORTANT: API_PROVIDERS WILL BE DEPRECATED WHEN ANGULAR 2 IS STABLE | ||
* PLEASE MIGRATE YOUR PROJECT AS SOON AS POSSIBLE. | ||
* ONCE ANGULAR 2 IS STABLE I WON'T KEEP SUPPORTING API PROVIDERS. | ||
* USER NGMODULE INSTEAD LOCATED IN ./sdk.module.ts | ||
**/ | ||
export const API_PROVIDERS: any[] = [ | ||
LoopBackAuth, | ||
ErrorHandler, | ||
LoggerService, | ||
JSONSearchParams,<% | ||
Object.keys(models).forEach(function(modelName, i, arr) { | ||
modelName = modelName[0].toUpperCase() + modelName.slice(1); | ||
%> | ||
<%- modelName %>Api<%= i < arr.length -1 ? ',' : '' %><% | ||
});%> | ||
]; | ||
<%- buildModuleImports(models, false) %> | ||
|
||
@NgModule({ | ||
imports: [ CommonModule, HttpModule ], | ||
declarations: [ ], | ||
exports: [ ], | ||
providers: [ ] | ||
}) | ||
|
||
export class SDKModule { | ||
static forRoot(): ModuleWithProviders { | ||
return { | ||
ngModule: SDKModule, | ||
providers: [ | ||
RealTime, | ||
LoopBackAuth, | ||
ErrorHandler, | ||
LoggerService, | ||
JSONSearchParams,<% | ||
Object.keys(models).forEach(function(modelName, i, arr) { | ||
modelName = modelName[0].toUpperCase() + modelName.slice(1); | ||
%> | ||
<%- modelName %>Api<%= i < arr.length -1 ? ',' : '' %><% | ||
});%> | ||
] | ||
}; | ||
} | ||
} | ||
|
||
export * from './models/index'; | ||
export * from './services/index'; | ||
export * from './lb.config'; | ||
export * from './sdk.module'; | ||
<% if ( isIo === 'enabled' ){ -%>export * from './sockets/index'; | ||
<% } | ||
-%> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,13 @@ | ||
/* tslint:disable */ | ||
<%- buildModelImports(model) %> | ||
declare var Object: any; | ||
export interface <%- modelName %>Interface { | ||
<%- buildModelProperties(model, true) %> | ||
} | ||
|
||
export class <%- modelName %> implements <%- modelName %>Interface { | ||
<%- buildModelProperties(model) %> | ||
constructor(instance?: <%- modelName %>) { | ||
constructor(instance?: <%- modelName %>Interface) { | ||
Object.assign(this, instance); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.