mizzao / meteor-bootstrap-3

Bootstrap 3 package for meteor
37 stars 10 forks source link

Wrong path for Glyphicons #5

Closed uncured closed 9 years ago

uncured commented 9 years ago

Hi there. On Meteor 0.9.3.1 (OS X 10.9.5) I have an issue with building your package. On client side at start-up warning appears just like that:

Resource interpreted as Font but transferred with MIME type text/html: "http://localhost:3000/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.woff". 
Resource interpreted as Font but transferred with MIME type text/html: "http://localhost:3000/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.ttf".
Resource interpreted as Font but transferred with MIME type text/html: "http://localhost:3000/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.svg".

As I dig deeper, I discovered strange issue in my .meteor/local/build/programs/web.browser/xxxxxxxxx.css - general css, generated in build time by meteor.

There is two css rules in this file. First one is

@font-face {
  font-family: 'Glyphicons Halflings';
  src: url('packages/mizzao_bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.eot');
  src: url('packages/mizzao_bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.eot?') format('embedded-opentype'), url('packages/mizzao_bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.woff') format('woff'), url('packages/mizzao_bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('packages/mizzao_bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.svg') format('svg');
}

And the second one is

/*# sourceMappingURL=bootstrap.css.map */
@font-face {
  font-family: 'Glyphicons Halflings';
  src: url('/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.eot');
  src: url('/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.woff') format('woff'), url('/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('/packages/mizzao:bootstrap-3/bootstrap-3/fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg');
}

Path packages/mizzao_bootstrap-3 from first rule is the right one. But it's overriden with the second (wrong) path rule /packages/mizzao:bootstrap-3. And it is the cause of this trouble.

I don't understand any of this transforms as long as my ~/.meteor/packages/ contains all of this packages with names like mizzao/bootstrap-3 (it gets my brain collapse just to see / in folder names).

mizzao commented 9 years ago

Are you actually building the package or is this just #3? I'll publish a fix for that today.

mizzao commented 9 years ago

Can you please update to version 3.2.0_1 and let me know if you are still seeing this issue?

uncured commented 9 years ago

Thank you, Andrew. It worked. Warnings gone away.