Comments (8)
Ah... so, the source you link to is total bullshit, and I hate it, but sprockets + the railtie are such crap that it requires us to do that. Honestly, it drives me nuts.
And yes, external scripts are an oversight. How would you like it to be implemented? To include external libraries like this in your suite.javascripts
configuration, or some other means?
from teaspoon.
Looking at my own projects, it seems like it'd have to be either in the suite config or in spec_helper.
The advantage of putting it in the suite config is that it'd be clean. The advantage of spec_helper is that I'm already putting my other dependencies in spec_helper, so it'd seem a natural place to put external libraries (although it's markedly different to what people are used to with sprockets)
Another option might just be asynchronously loading the external dependencies (by adding a script tag to the page) in spec_helper, which (I think) would work without any changes to teabag itself.
from teaspoon.
I went with adding the ability from within the suite config.. hopefully that covers the need.
I wish sprockets supported it itself though: sstephenson/sprockets#289
from teaspoon.
Can you give an example of how this works?
from teaspoon.
For example, if I want to include externally hosted javascript files on every suite, what do I need to do to get this up and running with teaspoon?
from teaspoon.
Hey sorry I figured this out, didn't read the docs carefully enough!
from teaspoon.
What is the solution here? I know I can make a boot partial where I can download what I need, but it's far from ideal.
from teaspoon.
you should be able to put them in the configuration in 0.8 (master)
suite.javascripts << ['//cdn.com/jquery']
from teaspoon.
Related Issues (20)
- Support for Jasmine 3 HOT 1
- Add Support for Istanbul-nyc HOT 2
- javascript_include_tag needs to support new nonce: true option HOT 9
- New release HOT 3
- teaspoon 1.2.0 causes Teaspoon::EnvironmentNotFound error HOT 13
- Selenium Timeout with Rails 6 HOT 10
- Coverage output path ignored in 1.2.0 HOT 3
- Reload window on every jasmine spec in teaspoon HOT 1
- Browser console output should be logged to log/development.log HOT 2
- TypeError: undefined is not an object (evaluating 'window.SpreePaths.mounted_at') HOT 3
- [ANN] Looking for a new maintainer HOT 2
- Ruby 3.0.0 HOT 2
- Migrate from Travis to use Github Actions HOT 1
- Support newer version of Jasmine
- How to use headless chrome with Teaspoon
- Coverage when specs are in test/dummy HOT 1
- Is teaspoon-mocha actively managed? HOT 3
- Sprockets 4 support
- Not getting coverage reports after upgrading from rails 5 to rails 6 HOT 3
- Code coverage not working with Puma 6.2 HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from teaspoon.