Skip to content

fix(): fixed paths internal in files #270

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

Brocco
Copy link
Contributor

@Brocco Brocco commented Mar 2, 2016

The paths/url references inside files were not changed to allow for dynamic paths
Added the ability to utlize dynamic paths from within the project structure

return {
__name__: function(options) {
return options.locals.name;
return _this.dynamicPath.name;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Try out arrow functions, it will simplify your code greatly. And they've been in Node for a while now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I keep forgetting that... I use them a lot when doing TypeScript so when I'm doing JavaScript I think I'm always restricted to ES5 syntax. Good catch, new PR pushed!

@Brocco Brocco force-pushed the fix-component-paths branch from b0077c6 to 8fe07c6 Compare March 3, 2016 05:09
@filipesilva
Copy link
Contributor

Could you add a few tests in e2e_workflow.js to make sure the dynamic paths are working btw?

Also I see some the new blueprints for services, but not the supporting file changes (like locals or fileMapTokens with defaults in blueprints/service/index.js) nor the removal of the old absolute pathed blueprints. Is this intended?

@Brocco
Copy link
Contributor Author

Brocco commented Mar 4, 2016

@filipesilva instead of adding tests to the e2e workflow suite, I added a new acceptance test to handle the testing of generating components

@IgorMinar
Copy link
Contributor

I haven't reviewed every single line, but at a high level this looks good to me

@Brocco Brocco force-pushed the fix-component-paths branch from 098f03d to be76283 Compare March 4, 2016 21:12
@@ -0,0 +1,180 @@
'use strict';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A minor thing, but shouldn't the file be named generate-component.spec.js? We overall go for dash separated file names, and reserve the dots to separate functionality groups.

@filipesilva
Copy link
Contributor

@Brocco tests look good, and now we have appveyor so we can tests on windows as well.

What about the changes to services though, what are they for? Do they also support relative path names? I don't quite understand why these files are also in the PR.

@Brocco Brocco force-pushed the fix-component-paths branch 2 times, most recently from 133c98f to fe86edb Compare March 6, 2016 16:40
@Brocco
Copy link
Contributor Author

Brocco commented Mar 7, 2016

@filipesilva I want to use this a test to see how the path structuring feels after some usage before fully integrating into all other generations. Also, awaiting on a more stabilized best practices project structure.

} else if (cwd.indexOf(rootPath) >= 0) {
outputPath = path.join(cwd, entityName);
} else if (cwd.indexOf(path.join(this.project.root, 'src')) >= 0
&& entityName.indexOf('app') === 0) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

left aligned inside the ( of the if.

The paths/url references inside files were not changed to allow for dynamic paths
Added the ability to utlize dynamic paths from within the project structure
@Brocco Brocco force-pushed the fix-component-paths branch from fe86edb to 65dc91b Compare March 8, 2016 01:26
@hansl
Copy link
Contributor

hansl commented Mar 8, 2016

LGTM.

@Brocco Brocco closed this in 09193e4 Mar 8, 2016
@Brocco Brocco deleted the fix-component-paths branch March 8, 2016 02:02
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants