Skip to content
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

Introduce a build_path variable #35

Open
RobLoach opened this issue Jan 6, 2017 · 5 comments
Open

Introduce a build_path variable #35

RobLoach opened this issue Jan 6, 2017 · 5 comments

Comments

@RobLoach
Copy link
Contributor

RobLoach commented Jan 6, 2017

It should be exposed through the twigshim hook.

It should default to base_path() . kalastatic_base . kalastatic_destination.

https://api.drupal.org/api/drupal/includes!common.inc/function/base_path/7.x

@hawkeyetwolf
Copy link

Hey @RobLoach, did we need build_path when rendering Twig templates from Drupal for any reason? It breaks image paths we pass into the Twig templates. Talked it over with @thiagodemellobueno and it seems that when rendering from Drupal, we are not in fact supposed to have this variable set. Okay if we take it out?

@hawkeyetwolf hawkeyetwolf reopened this Jan 31, 2017
@RobLoach
Copy link
Contributor Author

RobLoach commented Jan 31, 2017

build_path breaks images in Drupal? Just having the variable shouldn't break things. This on PROG? I'd rather fix it in there....
https://kalamuna.atlassian.net/browse/PROGMI-242

Do you have a link to see where it's broken?

The aim of build_path is to represent the path in which KalaStatic was built to. The workaround we used when this wasn't available is src_root.

@hawkeyetwolf
Copy link

hawkeyetwolf commented Feb 8, 2017

@RobLoach is anything still needed here? I think we cleaned up the problem and are on the same page about how/why build_path was giving us a headache (if more 'splanation is needed, lemme know). We talked about a more permanent solution last week but not sure how far we got with implementing it.

@RobLoach
Copy link
Contributor Author

RobLoach commented Feb 8, 2017

@derekderaps Think Josh decided static_asset_path was a better name:
https://github.com/kalamuna/kalastatic_dot_module/blob/7.x-2.x/kalastatic.module#L357

In PROGMI, the solution was to get rid of it all and have all image paths prefix /kalastatic/ manually, avoiding the issue all together.

@hawkeyetwolf
Copy link

re:

In PROGMI, the solution was to get rid of it all and have all image paths prefix /kalastatic/ manually, avoiding the issue all together.

Smart one! Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants