Skip to content
This repository has been archived by the owner on Jul 16, 2021. It is now read-only.

[Proposal] Asset domain configuration #392

Closed
dwightwatson opened this issue Jan 28, 2017 · 2 comments
Closed

[Proposal] Asset domain configuration #392

dwightwatson opened this issue Jan 28, 2017 · 2 comments

Comments

@dwightwatson
Copy link

I've noticed that the mix helper returns an absolute URL for assets, where the elixir helper would return a relative one. However, you might not always want to be serving your assets from the same URL as the app. For example, a CDN that might sit in front of your app and cache assets.

I'd like to propose a second URL be added in config/app.php or wherever else is appropriate, something like asset_url. It could default to the primary URL but changed if necessary.

Is this a PR you'd consider? Otherwise, is the functionality I'm after already available in another way?

@m1guelpf
Copy link

@dwightwatson So this can be closed?

@dwightwatson
Copy link
Author

I still think it would be beneficial to have some sort of asset_url configuration so that it would be easy to use a CDN with your apps. The PR I made above was just updated Mix to return a relative path rather than an absolute path so it's easier to replace with another host if you need.

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

No branches or pull requests

3 participants