Skip to content

Releases: static-dev/spike-core

v0.11.0

12 Aug 21:40
Compare
Choose a tag to compare

v0.10.0

04 Aug 22:39
Compare
Choose a tag to compare
  • Eliminate extra html parsing, which was causing slowdowns and a bug with reloading in watch mode. This should boost compile speed significantly.

v0.9.0

19 Jul 15:20
Compare
Choose a tag to compare

Caution: Breaking Release!

  • Upgrade dependencies, specifically posthtml-loader

Upgrade Path

  • In the posthtml settings, change the defaults key to plugins

v0.8.2

07 Jul 18:48
Compare
Choose a tag to compare
  • Fix a bug with global config path creation

v0.8.1

21 Jun 19:31
Compare
Choose a tag to compare
  • Exposes global config function on the primary spike class
  • Adds a unique id to the global config file
  • This doesn't break anything and will make no difference in your projects ✨

v0.8.0

20 Jun 20:38
Compare
Choose a tag to compare

BREAKING RELEASE This will break all spike apps, beware! ⛔

Hello friends! Time for a big release 😁 As you may have seen above, this update with unquestionably break all existing spike projects, there have been some massive architecture changes for the better. Luckily, upgrading isn't too tough. Let's go through what changed.

  • We switched from pure jade to posthtml. This means a huge amount more flexibility, as you can plug any of a large number of posthtml plugins in order to transform your html. We also are not giving up jade entirely, the default template uses posthtml-jade, so nothing will need to change in your views.
  • The default extensions are now html, css, and js instead of jade, sss, and js, as they were previously. That means if you want to use custom extensions to match posthtml/postcss plugins, you will need to configure them manually.
  • We no longer auto-include postcss-include, because it was ridiculous that we did this before. The user should be entirely in control of their own postcss plugins. If you are using this plugin, you will need to add it to your app.js file now.
  • The locals config option no longer exists. With posthtml, you can use plugins that include locals in a variety of ways, user's preference. You can now pass locals directly to the jade plugin if you're using jade.
  • Removing locals means that spike-rooftop and spike-records now work a little differently, so if you are using either of these plugins, you will need to update your version and configuration. Check out their readmes for more details.

Typical Upgrade Path

  • Run npm i spike-util posthtml-jade postcss-import -S
  • Add matchers: { html: '**/*.jade', css: '**/*.sss' } to your app.js config, so that the custom extensions are matched correctly.
  • Add a posthtml config that looks like this:
const Util = require('spike-util')
const jade = require('posthtml-jade')
// ...
module.exports = {
  // ...
  posthtml: (ctx) => {
      const f = Util.filePathFromLoader(ctx).absolute
      return {
        defaults: [jade({ filename: f, pretty: true, foo: 'bar' })]
      }
    }
  // ...
}
  • If you are using locals, pass them right into the config object going into jade, an example foo: 'bar' is provided above.
  • Update your postcss config to use postcss-imports, as such:
const postcssImport = require('postcss-import')
// ...
module.exports = {
  // ...
  postcss: (ctx) => {
    const atImport = postcssImport({ addDependencyTo: ctx })
    return {
      plugins: [atImport, cssnext(), rucksack(), lost()],
      parser: sugarss
    }
  }
  // ...
}
  • If you are using spike-records or spike-rooftop, consult those projects' readmes for upgrade info, and boost the version.
  • If all else fails, consult the app.js in our base template, which is working.
  • If this still fails, come say hi in our gitter chatroom and we will help you out 😁

v0.7.0

14 Jun 16:46
Compare
Choose a tag to compare
  • BREAKING: project.compile() now returns an object containing the id and compiler rather than an array
  • BREAKING: project.watch() now returns an object containing the id and watcher rather than just the watcher
  • Custom loaders now work along with spike's core plugins, unless you pass the skipSpikeProcessing: true option to them. This means that a file processed by a custom loader does not need to be required and will be written to the output folder. See the new custom loaders docs for more information. To restore loader behavior exactly to how it was in the previous version, pass the skipSpikeProcessing: true flag along with the loader config.
  • Source maps are now generated without error using the devtool config.
  • New and better documentation in the readme! 🎉

v0.6.2

10 Jun 15:54
Compare
Choose a tag to compare
  • It's now impossible to mess up the formatting of the entry option
  • postcss querystring options are now passed through correctly, just add to the postcss object as usual
  • new css option allows you to pass options to the css-loader
  • dependencies updated

v0.6.1

08 Jun 18:44
Compare
Choose a tag to compare
  • Update source loader such that it does not attempt to stringify binary files anymore
  • If anyone has run into an "unterminated string constant" error, this should take care of it.

v0.6.0

03 Jun 17:06
Compare
Choose a tag to compare
  • Change event name from done to success on all template methods to prevent conflict with the done event on Spike.new within the CLI.