Skip to content

Conversation

@snvfk1n
Copy link

@snvfk1n snvfk1n commented Mar 5, 2016

Referencing #182. Added a small HTTP server (test/helpers/fixture-server.js) to perform tests in test/remote.js. All passing so far!

Edit: Argh, didn't know each commit shows up individually...

stmt.uri = "http:" + stmt.uri
}
}
// skip non-html protocol base uri (protocol://url)
Copy link
Member

Choose a reason for hiding this comment

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

non-http

@TrySound
Copy link
Member

TrySound commented Mar 6, 2016

@fallafeljan Can you make this feature inside resolver and loader without editing index.js?

{
"name": "postcss-import",
"version": "8.0.2",
"version": "8.0.3",
Copy link
Member

Choose a reason for hiding this comment

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

Don't do this too,

Copy link
Contributor

Choose a reason for hiding this comment

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

+1

@snvfk1n
Copy link
Author

snvfk1n commented Mar 6, 2016

Not without editing index.js at all, since all protocol-based imports are ignored by default. I'm looking into putting most feature code into resolver & loader and just change the protocol matching regex to pass http://, https:// and //.

@TrySound
Copy link
Member

TrySound commented Mar 6, 2016

@fallafeljan Okay. We can not filter url in the next major release.

@TrySound
Copy link
Member

TrySound commented Mar 6, 2016

@fallafeljan Can you choose something different of request-promise. That dep seems too big.

@snvfk1n
Copy link
Author

snvfk1n commented Mar 6, 2016

@TrySound sure, I'll just look for something with less deps – any recommendations?

Pardon, what do you mean by "filter url"? Changing the index.js protocol filtering?

@TrySound
Copy link
Member

TrySound commented Mar 6, 2016

@fallafeljan We can pass false in resolve function or maybe add some fitler option.

@snvfk1n
Copy link
Author

snvfk1n commented Mar 6, 2016

So moving the protocol checking from parseStyles of index.js into resolve-id.js and filter by rejecting the promise in resolveId?

@TrySound
Copy link
Member

TrySound commented Mar 6, 2016

@fallafeljan Not now. When we will be ready for major. Now just leave it.

@MoOx
Copy link
Contributor

MoOx commented Apr 4, 2016

@TrySound I found your comment confusing.

It's not a big deal to make a breaking change.

@TrySound
Copy link
Member

TrySound commented Apr 4, 2016

@MoOx Yeah, I know. I just don't have a lot time on my new work for open source these days. Maybe next week.

@MoOx
Copy link
Contributor

MoOx commented Apr 4, 2016

Ok no hurry, I just wanted to know if you were ok ;)

@ElRaph
Copy link

ElRaph commented Sep 5, 2016

If someone else needs this functionality, it could be found there: https://github.com/unlight/postcss-import-url

@MoOx
Copy link
Contributor

MoOx commented Sep 6, 2016

Cool! So I am closing!

@MoOx MoOx closed this Sep 6, 2016
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

Successfully merging this pull request may close these issues.

5 participants