Socket
Socket
Sign inDemoInstall

dgeni-packages

Package Overview
Dependencies
Maintainers
1
Versions
147
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dgeni-packages - npm Package Compare versions

Comparing version 0.9.4 to 0.9.5

8

CHANGELOG.md

@@ -0,3 +1,11 @@

## v0.9.5 07/17/2014
* fix(ng-doc/component-groups-generate): allow path/outputPath to be configurable 48d105bc
* Revert "fix(ng-doc/component-groups-generate processor): use path/outputPath specified in process... 71ced7dd
## v0.9.4 07/17/2014
** WARNING - this release had an invalid breaking change. Don't use it **
* fix(utils/code): encode HTML entities 5091e1c1

@@ -4,0 +12,0 @@ * fix(ng-doc/component-groups-generate processor): use path/outputPath specified in processing.api-... f2c3776f

13

ngdoc/processors/component-groups-generate.js

@@ -16,6 +16,6 @@ var _ = require('lodash');

var apiConfig = config.get('processing.api-docs');
if ( !apiConfig ) {
throw new Error('Invalid configuration. You must provide config.processing.api-docs');
}
var options = _.assign({
outputPath: '${module.area}/${module.name}/${docType}/index.html',
path: '${module.area}/${module.name}/${docType}'
}, config.get('processing.component-groups', {}));

@@ -31,3 +31,2 @@ _.forEach(moduleMap, function(module) {

.map(function(docs, docType) {
var templateParams = { area: module.area, module: module.name, docType: docType, name: 'index'};
return {

@@ -41,4 +40,4 @@ id: module.id + '.' + docType,

components: docs,
outputPath: path.join(partialsPath, _.template(apiConfig.outputPath, templateParams)),
path: _.template(apiConfig.path, templateParams)
outputPath: path.join(partialsPath, _.template(options.outputPath, { module: module, docType: docType })),
path: _.template(options.path, { module: module, docType: docType })
};

@@ -45,0 +44,0 @@ })

@@ -6,3 +6,2 @@ var _ = require('lodash');

describe("component-groups processor", function() {
it("should create a new doc for each group of components (by docType) in each module", function() {

@@ -25,15 +24,9 @@ var docs = [];

config.set('rendering.contentsFolder', 'partials');
config.set('processing.api-docs', {
outputPath: '${area}/${module}/${docType}/${name}.html',
path: '${area}/${module}/${docType}/${name}'
});
processor.process(docs, config, modules);
expect(docs.length).toEqual(2);
});
it("should use the outputPath and path specified in processing.api-docs", function() {
it("should use the outputPath and path specified in processing.component-groups", function() {
var docs = [];

@@ -57,5 +50,5 @@ var modules = [{

config.set('rendering.contentsFolder', 'partials');
config.set('processing.api-docs', {
outputPath: '${area}/${module}/${docType}/${name}.html',
path: '${area}/${module}/${docType}/${name}'
config.set('processing.component-groups', {
outputPath: '${module.area}/${module.name}/${docType}/${module.name}.html',
path: '${module.area}/${module.name}/${docType}/${module.name}'
});

@@ -65,8 +58,5 @@

expect(docs[0].path).toBe('api-docs/test/a/index');
expect(docs[0].outputPath).toBe('partials/api-docs/test/a/index.html');
expect(docs[0].path).toBe('api-docs/test/a/test');
expect(docs[0].outputPath).toBe('partials/api-docs/test/a/test.html');
});
});
{
"name": "dgeni-packages",
"version": "0.9.4",
"version": "0.9.5",
"description": "A collection of dgeni packages for generating documentation from source code",

@@ -5,0 +5,0 @@ "scripts": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc