teamcfadvance / cfstatic

CfStatic is a framework for managing the inclusion and packaging of CSS and JavaScript in CFML applications.
https://teamcfadvance.github.io/cfstatic
MIT License
102 stars 35 forks source link

Support for CF Mappings #83

Closed CameronJ closed 11 years ago

CameronJ commented 11 years ago

Support for ColdFusion Mappings would be great. I've got code that I use globally and generally just import it using a coldfusion mapping and apache Alias

DominicWatson commented 11 years ago

I use mapped paths with cfstatic without any problems. What is the error you are seeing?

CameronJ commented 11 years ago

It seems, based on browsing your code, that the issue is with the logic that parses the directories on disk. I'm running a windows system and not using symbolic links. So if you parse the physical directory structure of the "staticDirectory", it wouldn't include any directories that are mappings.

Additionally, it doesn't appear to be possible to include a js or css file that isn't inside the staticDirectory/jsDirectory or staticDirectory/cssDirectory. This I believe is the problem that I'm running into, which is referenced in a different issue, allowing multiple staticDirectories.

CameronJ commented 11 years ago

Sorry, just realized I didn't specifically answer your question. There was no error... it just didn't do it. Based on working with this tool, it appears that it just ignores you if you try to include a local dependency that it hasn't found in the directory (and assigned priorities to).

CameronJ commented 11 years ago

Also, to add more detail to my initial problem. The use of CF Mappings isn't directly the problem. It's the use of JS and CSS assets from within the mapping.

DominicWatson commented 11 years ago

This is a tricky one I think. One of the issues is with those mapped directories, I'm thinking that CfStatic is going to have to assume that they're web accessible in the same path (for debug mode).

I'm going to close this with the assumption that it will be dealt with when looking at multiple source directories.