Skip to content

Commit

Permalink
[FIX] manifestCreator: Only consider component files called Component…
Browse files Browse the repository at this point in the history
….js (#273)

In the past files called *Component.js where also considered as
Components during manifest creation.
  • Loading branch information
RandomByte authored Sep 20, 2019
1 parent 327cca0 commit 82fe267
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lib/processors/manifestCreator.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ async function createManifest(libraryResource, libBundle, descriptorVersion, _in
function findComponentPaths() {
const result = [];
const prefix = libraryResource.getPath().slice(0, - ".library".length);
const components = libBundle.getResources(/(?:[^/]+\/)*Component\.js$/);
const components = libBundle.getResources(/^\/(?:[^/]+\/)*Component\.js$/);
components.forEach((comp) => {
const relativePath = comp.getPath().slice(prefix.length);
if ( relativePath.lastIndexOf("/") >= 0 ) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
sap.ui.require.preload({
"library/h/components/Component.js":function(){sap.ui.define(["sap/ui/core/UIComponent"],function(n){"use strict";return n.extend("application.g.Component",{})});
},
"library/h/components/TodoComponent.js":function(){/*!
* Some fancy copyright
*/
console.log(" File ");
}
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/*!
* Some fancy copyright
*/
console.log(" File ");
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/*!
* ${copyright}
*/
console.log(' File ');

0 comments on commit 82fe267

Please sign in to comment.