🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@ionic/cli-plugin-ionic-angular

Package Overview
Dependencies
Maintainers
12
Versions
263
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ionic/cli-plugin-ionic-angular - npm Package Compare versions

Comparing version

to
1.4.0-alpha.4323e35f

13

dist/generate.js

@@ -16,3 +16,3 @@ "use strict";

process.argv = ['node', 'appscripts'].concat(appScriptsArgs);
const ionicAngularPackageJsonFilePath = path.resolve(args.env.project.directory, 'node_modules', 'ionic-angular', 'package.json');
const ionicAngularPackageJsonFilePath = path.resolve(args.env.project.directory, 'node_modules', 'ionic-angular', 'package.json'); // TODO
try {

@@ -30,16 +30,17 @@ const ionicAngularPackageJson = yield cli_utils_1.readPackageJsonFile(ionicAngularPackageJsonFilePath);

const [type, name] = args.inputs;
const commandOptions = args.options;
switch (type) {
case 'page':
yield AppScripts.processPageRequest(context, name);
yield AppScripts.processPageRequest(context, name, commandOptions);
break;
case 'component':
const componentData = yield promptQuestions(context);
const componentData = yield generate_1.getModules(context, 'component');
yield AppScripts.processComponentRequest(context, name, componentData);
break;
case 'directive':
const directiveData = yield promptQuestions(context);
const directiveData = yield generate_1.getModules(context, 'directive');
yield AppScripts.processDirectiveRequest(context, name, directiveData);
break;
case 'pipe':
const pipeData = yield promptQuestions(context);
const pipeData = yield generate_1.getModules(context, 'pipe');
yield AppScripts.processPipeRequest(context, name, pipeData);

@@ -53,3 +54,3 @@ break;

const tabsData = yield generate_1.tabsPrompt(args.env);
yield AppScripts.processTabsRequest(context, name, tabsData);
yield AppScripts.processTabsRequest(context, name, tabsData, commandOptions);
break;

@@ -56,0 +57,0 @@ }

@@ -11,6 +11,6 @@ "use strict";

exports.name = '@ionic/cli-plugin-ionic-angular';
exports.version = '1.4.0-alpha.36dc2f70';
exports.version = '1.4.0-alpha.4323e35f';
function getIonicAngularVersion(env) {
return tslib_1.__awaiter(this, void 0, void 0, function* () {
const ionicAngularPackageJsonFilePath = path.resolve(env.project.directory, 'node_modules', 'ionic-angular', 'package.json');
const ionicAngularPackageJsonFilePath = path.resolve(env.project.directory, 'node_modules', 'ionic-angular', 'package.json'); // TODO
try {

@@ -27,3 +27,3 @@ const ionicAngularPackageJson = yield cli_utils_1.readPackageJsonFile(ionicAngularPackageJsonFilePath);

return tslib_1.__awaiter(this, void 0, void 0, function* () {
const appScriptsPackageJsonFilePath = path.resolve(env.project.directory, 'node_modules', '@ionic', 'app-scripts', 'package.json');
const appScriptsPackageJsonFilePath = path.resolve(env.project.directory, 'node_modules', '@ionic', 'app-scripts', 'package.json'); // TODO
try {

@@ -30,0 +30,0 @@ const appScriptsPackageJson = yield cli_utils_1.readPackageJsonFile(appScriptsPackageJsonFilePath);

@@ -1,4 +0,2 @@

import { CommandHookArgs } from '@ionic/cli-utils';
export declare function serve(args: CommandHookArgs): Promise<{
[key: string]: any;
}>;
import { CommandHookArgs, ServeCommandHookResponse } from '@ionic/cli-utils';
export declare function serve(args: CommandHookArgs): Promise<ServeCommandHookResponse>;

@@ -39,2 +39,4 @@ "use strict";

const context = AppScripts.generateContext();
// using app-scripts and livereload is requested
// Also remove commandName from the rawArgs passed
args.env.log.info(`Starting app-scripts server: ${chalk.bold(appScriptsArgs.join(' '))} - Ctrl+C to cancel`);

@@ -52,5 +54,5 @@ const settings = yield AppScripts.serve(context);

(localAddress !== externalAddress ? `External: ${chalk.bold(externalAddress)}` : ''));
return Object.assign({ publicIp: chosenIP, protocol: 'http' }, settings);
return Object.assign({ publicIp: chosenIP, protocol: 'http', localAddress: 'localhost', externalAddress: chosenIP, port: settings.httpPort }, settings);
});
}
exports.serve = serve;

@@ -9,2 +9,3 @@ import { IonicEnvironment } from '@ionic/cli-utils';

export declare function prompt(context: AppScriptsType.BuildContext): Promise<string>;
export declare function getModules(context: AppScriptsType.BuildContext, kind: string): Promise<string>;
export declare function tabsPrompt(env: IonicEnvironment): Promise<string[]>;

@@ -28,2 +28,15 @@ "use strict";

exports.prompt = prompt;
function getModules(context, kind) {
return tslib_1.__awaiter(this, void 0, void 0, function* () {
switch (kind) {
case 'component':
return context.componentsNgModulePath ? context.componentsNgModulePath : context.appNgModulePath;
case 'pipe':
return context.pipesNgModulePath ? context.pipesNgModulePath : context.appNgModulePath;
case 'directive':
return context.directivesNgModulePath ? context.directivesNgModulePath : context.appNgModulePath;
}
});
}
exports.getModules = getModules;
function tabsPrompt(env) {

@@ -30,0 +43,0 @@ return tslib_1.__awaiter(this, void 0, void 0, function* () {

{
"name": "@ionic/cli-plugin-ionic-angular",
"version": "1.4.0-alpha.36dc2f70",
"version": "1.4.0-alpha.4323e35f",
"description": "Ionic CLI build plugin for Ionic Angular projects",

@@ -10,3 +10,3 @@ "homepage": "https://ionic.io/",

"clean": "rm -rf ./dist",
"lint": "tslint --config ../../tslint.json --project tsconfig.json --type-check",
"lint": "tslint --config ../../tslint.js --project tsconfig.json --type-check",
"build": "npm run clean && npm run build-ts && npm run build-js",

@@ -46,3 +46,3 @@ "build-ts": "tsc",

"dependencies": {
"@ionic/cli-utils": "1.6.0-alpha.36dc2f70",
"@ionic/cli-utils": "1.6.0-alpha.4323e35f",
"chalk": "^2.0.0",

@@ -55,4 +55,4 @@ "tslib": "^1.7.1"

"@angular/core": "^4.2.4",
"@ionic/app-scripts": "^2.0.0",
"@ionic/cli-scripts": "0.3.0-alpha.36dc2f70",
"@ionic/app-scripts": "^2.1.0",
"@ionic/cli-scripts": "0.3.0-alpha.4323e35f",
"@types/chalk": "^0.4.31",

@@ -59,0 +59,0 @@ "@types/clean-css": "^3.4.30",