profile
viewpoint

getkirby-v2/plugins 239

Kirby plugins from getkirby.com. Extensions, fields and widgets

stefaang/bitcoin_biller 1

Create receipts with a bitcoin QR code

stefaang/kingler 1

Multiplayer geoposition game engine, based on Flask, socketIO, MongoDB and Leaflet

thgh/deno-rollup 1

Rollup CLI for deno

thgh/ethicsandsport.com 1

Static assets for ethicsandsport.com

thgh/gitroom 1

Collaborate on a git branch by syncing your working directory

AlanaMarie/bottems-up 0

Hackaton respository

cskiwi/VPW 0

Vlaamse programeer wedstrijd

Juta/SKIscanner 0

Use Skyscanner to fly to the cheapest ski resorts and become a ski champion

issue openedjustinlettau/azure-ad-verify-token

Cannot read property 'header' of null

Invalid tokens might be null: https://github.com/auth0/node-jsonwebtoken/blob/5f10bf9957a2541828501cfecab0310908b2f62f/decode.js#L6

That why this code throws Cannot read property 'header' of null https://github.com/justinlettau/azure-ad-verify-token/blob/b0fbe8c966d549a90ff12f9a3b31595aad547d58/src/verify.ts#L54-L55

Instead, it would make sense to throw an 'invalid token' error like here: https://github.com/auth0/node-jsonwebtoken/blob/5f10bf9957a2541828501cfecab0310908b2f62f/verify.js#L75

created time in 2 days

issue openedjustinlettau/azure-ad-verify-token

Optimise cache

Describe the Issue

If two simultaneous requests use verify(), the jwksUri will be fetched twice.

Expected behavior

It should only fetch once per jwksUri.

Steps to Reproduce

await verify(a, config)
await verify(a, config)

Other Information

Change the cache to Map<string, Promise> and save the fetch Promise.

created time in 2 days

issue commentthgh/now-sapper

Using `node/fs` causes serverless issues

Looks like the function exits sooner than it reads the file which lambda does not seem to like. How about waiting for the file to be read?

For serverless to work properly, you should write your code as if every invocation starts from scratch. You can cache values, but you shouldn't try to run async stuff (reading files) after your function has completed.

tetigi

comment created time in 3 days

PR opened tetigi/my-sapper-app

Possible fix
+3 -6

0 comment

1 changed file

pr created time in 3 days

push eventthgh/my-sapper-app

Thomas Ghysels

commit sha 49279eb7928dc0f577cb00a469b4450ebae20f5b

Possible fix

view details

push time in 3 days

fork thgh/my-sapper-app

Example App To Demonstrate Fs Issues

https://my-sapper-app.now.sh

fork in 3 days

issue commentthgh/now-sapper

Generated `index.js` is too large

Don't install the node package. It's built in: import * as fs from 'fs'

tetigi

comment created time in 3 days

push eventthgh/rollup-plugin-livereload

Thomas Ghysels

commit sha 2b71df146cc9795f9f8b40843c641fa800cbe50e

Sync yarn.lock

view details

push time in 8 days

delete branch thgh/rollup-plugin-livereload

delete branch : revert-36-update-livereload

delete time in 8 days

push eventthgh/rollup-plugin-livereload

amio

commit sha aa7c65c7238d843467be48629b2548402d2ae448

chore: update livereload to 0.9.1

view details

Thomas Ghysels

commit sha ff9f5c77172f3329d712d800ab821cc5fc38a6b5

Merge pull request #39 from amio/update-livereload chore: update livereload to 0.9.1

view details

push time in 8 days

create barnchthgh/rollup-plugin-livereload

branch : revert-36-update-livereload

created branch time in 8 days

push eventthgh/rollup-plugin-livereload

Thomas Ghysels

commit sha 0c730146c2a9e631909cc0c828186bd03231b1b3

v1.1.0

view details

push time in 8 days

pull request commentthgh/rollup-plugin-livereload

chore: update livereload to 0.9.1

Didn't see this one until now! Thanks!

amio

comment created time in 8 days

push eventthgh/rollup-plugin-livereload

amio

commit sha aa7c65c7238d843467be48629b2548402d2ae448

chore: update livereload to 0.9.1

view details

Thomas Ghysels

commit sha 2654828e943be9d4a10cad4a09396d7127bd46e3

Merge pull request #36 from amio/update-livereload chore: update livereload to 0.9.1

view details

push time in 8 days

PR merged thgh/rollup-plugin-livereload

chore: update livereload to 0.9.1

Thanks to chokidar v3, livereload reduced install size significantly in 0.9.x, we may take advantage of that too.

No breaking change in 0.9.x according to changelog

+1 -1

0 comment

1 changed file

amio

pr closed time in 8 days

create barnchthgh/rollup-plugin-livereload

branch : head.appendChild

created branch time in 9 days

issue closedthgh/rollup-plugin-livereload

Codesandbox

Hi is it possible to use livereload on codesandbox ?

I'm getting the following error:

Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('<URL>') does not match the recipient window's origin ('<URL>').

closed time in 9 days

jakobrosenberg

issue commentthgh/rollup-plugin-livereload

Codesandbox

Nice work! Released in v1.1.0 🎉

jakobrosenberg

comment created time in 9 days

push eventthgh/rollup-plugin-livereload

Jakob Rosenberg

commit sha aeec6b6f0d34580b7c8333761eef186ec3e3ccd4

codesandbox.io support

view details

Thomas Ghysels

commit sha 8e192db9fe7a9c9dfe2ce2036cdd75182381d115

Merge pull request #38 from jakobrosenberg/codesandbox codesandbox.io support

view details

push time in 9 days

issue commentthgh/rollup-plugin-livereload

Codesandbox

Can you make a PR that inserts the correct script based on process.env.CODESANDBOX_SSE or maybe process.env.SANDBOX_URL?

jakobrosenberg

comment created time in 10 days

issue commentthgh/rollup-plugin-livereload

Codesandbox

You can copy src/index.js to your project, edit as needed and import that instead. Like this: https://codesandbox.io/s/svelte-template-mo0zo

It looks like you are almost there, it seems to connect to the wrong port:

      const host = location.host.replace(/^([^\.]+)/, "$1-35729");
-     const src = `https://${host}/livereload.js?snipver=1&host=${host}`;
+     const src = `https://${host}/livereload.js?snipver=1&host=${host}&port=80`;
      document.write(`<script async src="${src}">\x3C/script>`);
jakobrosenberg

comment created time in 10 days

issue commentthgh/rollup-plugin-livereload

Codesandbox

Try adding ?host=ktznl-35729.sse.codesandbox.io to the livereload script. (found on https://www.npmjs.com/package/livereload-js)

Let's first get it working with manual configuration and then look if the plugin can support it.

jakobrosenberg

comment created time in 12 days

issue commentthgh/rollup-plugin-serve

historyApiFallback not working

Do you mind checking if rollup-plugin-serve@2.0.0-beta.0 has a working historyApiFallback?

UIX-Design

comment created time in 12 days

Pull request review commentthgh/rollup-plugin-serve

fix: Remove 500 error if file not found

 function serve (options = { contentBase: '' }) {       if (!error) {         return found(response, filePath, content)       }-      if (error.code !== 'ENOENT') {-        response.writeHead(500)-        response.end('500 Internal Server Error' +-          '\n\n' + filePath +-          '\n\n' + Object.values(error).join('\n') +-          '\n\n(rollup-plugin-serve)', 'utf-8')-        return-      }

This code was originally added to make a difference between 404 and other errors. By removing it, there are only 404s. How about changing the order instead:

if (!error) ...
-if (error.code !== 'ENOENT') ...
if (options.historyApiFallback) ...
+if (error.code !== 'ENOENT') ...
notFound()
virus2016

comment created time in 12 days

issue commentthgh/rollup-plugin-livereload

Codesandbox

Try setting clientUrl in the plugin options.

jakobrosenberg

comment created time in 16 days

issue commentthgh/rollup-plugin-livereload

Codesandbox

I'm getting ...:35729/livereload.js?snipver=1 net::ERR_CONNECTION_REFUSED so it seems the livereload port is not open.

How do other projects handle this?

jakobrosenberg

comment created time in 23 days

Pull request review commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

 import { createFilter } from 'rollup-pluginutils' export default function css (options = {}) {   const filter = createFilter(options.include || ['/**/*.css', '/**/*.scss', '/**/*.sass'], options.exclude)   let dest = options.output+  const runtime = options.runtime || require('node-sass')

By moving the call to require up here, the plugin won't catch possible errors: If runtime is not given and node-sass is not installed (for example someone upgrading) this will throw an error (module not found).

riri

comment created time in 24 days

Pull request review commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

     "index.es.js"   ],   "dependencies": {-    "node-sass": "4",     "rollup-pluginutils": "2"   },   "devDependencies": {     "rollup": "1",     "rollup-plugin-buble": "0",     "standard": "14"+  },+  "peerDependencies": {

If we keep node-sass as a dependency then this will be a minor version. If node-sass needs to be installed separately (more efficient) then this is a breaking change => major version.

I don't mind either (not actively using this package anymore).

riri

comment created time in 24 days

push eventthgh/rollup-plugin-scss

Jim Schofield

commit sha 7c1d2e6dc0adc52f502035bcfed686650a435d1e

Add option to include a directory to watch with `this.addWatchFile`

view details

Jim Schofield

commit sha 816a4b2c809b8a8778597010904988513314a9e8

Removing unecessary function

view details

Thomas Ghysels

commit sha 920548c9b8d6bb155e4b592def1a1c8e751a234d

Merge branch 'master' into feature/add-watch-dir-option

view details

Thomas Ghysels

commit sha a976513cbb4c432062f10d55c7b985636c1a7459

Merge pull request #34 from JimSchofield/feature/add-watch-dir-option Feature/add watch dir option

view details

push time in 24 days

PR merged thgh/rollup-plugin-scss

Feature/add watch dir option

Adding an option to point to a folder to watch changes. Trying to resolve issue where @import inside of scss files don't necessarily cause rollup to watch those files.

+15 -3

1 comment

2 changed files

JimSchofield

pr closed time in 24 days

push eventJimSchofield/rollup-plugin-scss

Thomas Ghysels

commit sha 47cb5b0d4ca3f86730ea8e0383afc277c19a3825

Ignore css output if it's not a string Fix #26 Resolve #37

view details

Thomas Ghysels

commit sha 638f927e7ad2a219dcd130ed67622fb5b31efc25

Add `node_modules/` in includePaths by default

view details

Thomas Ghysels

commit sha 5f7a7085d9286f6a1d2e639ba7afa25aa7d37226

v2.0.0

view details

Jack Prosser

commit sha d9a4dee0007459f2b5f382d00936235f18b2e836

Adding the ability to extend the data options Gives the ability to include things like variables and mixins across the entire scss.

view details

Jack Prosser

commit sha 64ec72e83cc025f98615a41a1ffe5e3aa45089d4

Changing data to prefix and updating the readme

view details

Thomas Ghysels

commit sha 151d3f362e694568531084a21700f5ce0b60d389

Refactor prefix option

view details

Thomas Ghysels

commit sha fa65e28019edc199a70198bd15c5c8f43a1ff681

v2.1.0

view details

Thomas Ghysels

commit sha 920548c9b8d6bb155e4b592def1a1c8e751a234d

Merge branch 'master' into feature/add-watch-dir-option

view details

push time in 24 days

Pull request review commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

 scss({   failOnError: true,    // Prefix global scss. Useful for variables and mixins.-  prefix: `@import "./fonts.scss";`+  prefix: `@import "./fonts.scss";`,++  // use a node-sass compatible compiler (like 'sass') instead

This would be more in line with the other documentation:

  // Use a node-sass compatible compiler (default: node-sass)
riri

comment created time in 24 days

Pull request review commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

     "dev": "rollup -cw",     "lint": "standard rollup.config.js index.es.js",     "fix": "standard --fix rollup.config.js index.es.js",-    "test": "cd test && rm -f output.* && rollup -c && cmp output.js expected.js && cmp output.css expected.css && cd ..",+    "test": "cd test/node-sass && rm -f output.* && rollup -c && cmp output.js ../expected.js && cmp output.css expected.css && cd ../..",

It would be easier to be able to test the library with just one command, for example like this:

    "test": "npm run test:node-sass && npm run test:sass",
riri

comment created time in 24 days

Pull request review commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

     "index.es.js"   ],   "dependencies": {-    "node-sass": "4",     "rollup-pluginutils": "2"   },   "devDependencies": {     "rollup": "1",     "rollup-plugin-buble": "0",     "standard": "14"+  },+  "peerDependencies": {

I think peerDependencies will show a warning even when the user correctly installed one of the compilers. Wouldn't it be better to warn only when the compiler is missing?

riri

comment created time in 24 days

Pull request review commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

 scss({   failOnError: true,    // Prefix global scss. Useful for variables and mixins.-  prefix: `@import "./fonts.scss";`+  prefix: `@import "./fonts.scss";`,++  // use a node-sass compatible compiler (like 'sass') instead+  runtime: require('sass')

Not a strong preference, but I would consider naming the option compiler, lib or sass

  compiler: require('sass')
riri

comment created time in 24 days

issue commentthgh/rollup-plugin-livereload

Codesandbox

Not sure how codesandbox would support that.

Do you have an example project?

jakobrosenberg

comment created time in a month

push eventthgh/util

Thomas Ghysels

commit sha de646c981608ea72772a56cb65208950b716a819

Fallback to process.env in knexfile-env

view details

Thomas Ghysels

commit sha 1b4df6775f3fe1f139e9e5e8e276d2a1e5b32367

v1.16.0

view details

push time in a month

push eventthgh/util

Thomas Ghysels

commit sha bbfe7787188cfb2e601440ad4b7f113968689bae

v1.15.0

view details

Thomas Ghysels

commit sha 2cbc7c1459e253822fead107a40f5a63fc07e64f

Fallback to process.env in knexfile-env

view details

push time in a month

delete branch thgh/tweet-to-html

delete branch : patch-1

delete time in a month

Pull request review commentthgh/rollup-plugin-serve

add major features from webpack-dev-server

 function serve (options = { contentBase: '' }) {     options = { contentBase: options }   }   options.contentBase = Array.isArray(options.contentBase) ? options.contentBase : [options.contentBase || '']+  options.contentBasePublicPath = options.contentBasePublicPath || '/'   options.port = options.port || 10001   options.headers = options.headers || {}   options.https = options.https || false   options.openPage = options.openPage || ''+  options.compress = !!options.compress+  options.serveIndex = options.serveIndex || (options.serveIndex === undefined)   mime.default_type = 'text/plain' -  const requestListener = (request, response) => {-    // Remove querystring-    const urlPath = decodeURI(request.url.split('?')[0])+  function setupProxy () {+    /**+     * Assume a proxy configuration specified as:+     * proxy: {+     *   'context': { options }+     * }+     * OR+     * proxy: {+     *   'context': 'target'+     * }+     */+    if (!Array.isArray(options.proxy)) {+      if (Object.prototype.hasOwnProperty.call(options.proxy, 'target')) {+        options.proxy = [options.proxy]+      } else {+        options.proxy = Object.keys(options.proxy).map((context) => {+          let proxyOptions+          // For backwards compatibility reasons.+          const correctedContext = context+            .replace(/^\*$/, '**')+            .replace(/\/\*$/, '') -    Object.keys(options.headers).forEach((key) => {-      response.setHeader(key, options.headers[key])-    })+          if (typeof options.proxy[context] === 'string') {+            proxyOptions = {+              context: correctedContext,+              target: options.proxy[context]+            }+          } else {+            proxyOptions = Object.assign({}, options.proxy[context])+            proxyOptions.context = correctedContext+          }++          proxyOptions.logLevel = proxyOptions.logLevel || 'warn' -    readFileFromContentBase(options.contentBase, urlPath, function (error, content, filePath) {-      if (!error) {-        return found(response, filePath, content)+          return proxyOptions+        })       }-      if (error.code !== 'ENOENT') {-        response.writeHead(500)-        response.end('500 Internal Server Error' +-          '\n\n' + filePath +-          '\n\n' + Object.values(error).join('\n') +-          '\n\n(rollup-plugin-serve)', 'utf-8')-        return+    }++    const getProxyMiddleware = (proxyConfig) => {+      const context = proxyConfig.context || proxyConfig.path++      // It is possible to use the `bypass` method without a `target`.+      // However, the proxy middleware has no use in this case, and will fail to instantiate.+      if (proxyConfig.target) {+        return createProxyMiddleware(context, proxyConfig)       }-      if (options.historyApiFallback) {-        const fallbackPath = typeof options.historyApiFallback === 'string' ? options.historyApiFallback : '/index.html'-        readFileFromContentBase(options.contentBase, fallbackPath, function (error, content, filePath) {-          if (error) {-            notFound(response, filePath)-          } else {-            found(response, filePath, content)+    }+    /**+     * Assume a proxy configuration specified as:+     * proxy: [+     *   {+     *     context: ...,+     *     ...options...+     *   },+     *   // or:+     *   function() {+     *     return {+     *       context: ...,+     *       ...options...+     *     };+     *   }+     * ]+     */+    options.proxy.forEach((proxyConfigOrCallback) => {+      let proxyMiddleware++      let proxyConfig =+        typeof proxyConfigOrCallback === 'function'+          ? proxyConfigOrCallback()+          : proxyConfigOrCallback++      proxyMiddleware = getProxyMiddleware(proxyConfig)++      function proxyHandle (req, res, next) {+        if (typeof proxyConfigOrCallback === 'function') {+          const newProxyConfig = proxyConfigOrCallback()++          if (newProxyConfig !== proxyConfig) {+            proxyConfig = newProxyConfig+            proxyMiddleware = getProxyMiddleware(proxyConfig)           }-        })-      } else {-        notFound(response, filePath)+        }++        // - Check if we have a bypass function defined+        // - In case the bypass function is defined we'll retrieve the+        // bypassUrl from it otherwise bypassUrl would be null+        const isByPassFuncDefined = typeof proxyConfig.bypass === 'function'+        const bypassUrl = isByPassFuncDefined+          ? proxyConfig.bypass(req, res, proxyConfig)+          : null++        if (typeof bypassUrl === 'boolean') {+          // skip the proxy+          req.url = null+          next()+        } else if (typeof bypassUrl === 'string') {+          // byPass to that url+          req.url = bypassUrl+          next()+        } else if (proxyMiddleware) {+          return proxyMiddleware(req, res, next)+        } else {+          next()+        }       }++      app.use(proxyHandle)+      // Also forward error requests to the proxy so it can handle them.+      // eslint-disable-next-line handle-callback-err+      app.use((error, req, res, next) => proxyHandle(req, res, next))     })   }    // release previous server instance if rollup is reloading configuration in watch mode   if (server) {-    server.close()+    server.kill()   } else {     closeServerOnTermination()   } +  app = new Express()++  // Implement webpack-dev-server features+  const features = {+    compress: () => {+      if (options.compress) {+        app.use(compress())+      }+    },+    proxy: () => {+      if (options.proxy) {+        setupProxy()+      }+    },+    historyApiFallback: () => {+      if (options.historyApiFallback) {+        const fallback =+          typeof options.historyApiFallback === 'object'+            ? options.historyApiFallback+            : typeof options.historyApiFallback === 'string'+              ? { index: options.historyApiFallback, disableDotRule: true } : null++        app.use(historyApiFallback(fallback))+      }+    },+    contentBaseFiles: () => {+      if (Array.isArray(options.contentBase)) {+        options.contentBase.forEach((item) => {+          app.use(options.contentBasePublicPath, Express.static(item))+        })+      } else {+        app.use(+          options.contentBasePublicPath,+          Express.static(options.contentBase, options.staticOptions)+        )+      }+    },+    contentBaseIndex: () => {+      if (options.contentBase && options.serveIndex) {+        const getHandler = item => function indexHandler (req, res, next) {+          // serve-index doesn't fallthrough non-get/head request to next middleware+          if (req.method !== 'GET' && req.method !== 'HEAD') {+            return next()+          }++          serveIndex(item)(req, res, next)+        }+        if (Array.isArray(options.contentBase)) {+          options.contentBase.forEach((item) => {+            app.use(options.contentBasePublicPath, getHandler(item))+          })+        } else {+          app.use(options.contentBasePublicPath, getHandler(options.contentBase))+        }+      }+    },+    before: () => {+      if (typeof options.before === 'function') {+        options.before(app)+      }+    },+    after: () => {+      if (typeof options.after === 'function') {+        options.after(app)+      }+    },+    headers: () => {+      app.all('*', function headersHandler (req, res, next) {+        if (options.headers) {+          for (const name in options.headers) {+            res.setHeader(name, options.headers[name])+          }+        }+        next()+      })+    }+  }++  const runnableFeatures = []

How much of this code is copied from webpack-dev-server?

pkit

comment created time in a month

Pull request review commentthgh/rollup-plugin-serve

add major features from webpack-dev-server

 function serve (options = { contentBase: '' }) {     options = { contentBase: options }   }   options.contentBase = Array.isArray(options.contentBase) ? options.contentBase : [options.contentBase || '']+  options.contentBasePublicPath = options.contentBasePublicPath || '/'   options.port = options.port || 10001   options.headers = options.headers || {}   options.https = options.https || false   options.openPage = options.openPage || ''+  options.compress = !!options.compress+  options.serveIndex = options.serveIndex || (options.serveIndex === undefined)

These new options should be documented in README.md

pkit

comment created time in a month

Pull request review commentthgh/rollup-plugin-serve

add major features from webpack-dev-server

     "dist"   ],   "dependencies": {+    "compression": "^1.7.4",+    "connect-history-api-fallback": "^1.6.0",+    "express": "^4.17.1",+    "http-proxy-middleware": "^1.0.0",+    "killable": "^1.0.1",     "mime": ">=2.0.3",-    "opener": "1"+    "opener": "1",+    "serve-index": "^1.9.1"

What do you think about moving all of these to devDependencies and bundling them in the plugin with rollup?

pkit

comment created time in a month

pull request commentthgh/rollup-plugin-serve

add major features from webpack-dev-server

This looks promising, but I don't have the time to review this completely so I hope somebody else can review.

I released the PR as rollup-plugin-serve@2.0.0-beta.0

pkit

comment created time in a month

pull request commentthgh/rollup-plugin-scss

added an option to choose the sass compiler

It looks like yarn run test won't pass, is it?

riri

comment created time in a month

issue commentsveltejs/sapper

Decouple Routes from code to be executed!

Just wanted to chime in and say that I needed this feature too.

Example 1: I want to POST to /render and show the result.

Example 2: I don't want to the frontend to be aware of admin pages. (or any page that should only be server generated)

Example 3: I want to add extra scripts, stylesheets, secrets, data to a specific page. (think of IE11 support)

Example 4: I want a multilingual site that supports both /about and /en/about. The problem is that /[lang]/index.svelte is ambiguous, params.lang could be a language or a slug.

The last example is probably possible by overwriting req.url now that I see it like that. I imagine an API for the others like this:

// src/routes/render.js
import { render } from '@sapper/server'
import Result from './Result.svelte'

export async function post (req, res) {
  res.end(await render(Result, req))
}
acewf

comment created time in a month

issue commentpwa-builder/PWABuilder

Downloaded zip does not contain iOS project

Maybe I confused macos and ios?

https://www.pwabuilder.com/publish Screenshot 2020-02-14 at 21 45 49

thgh

comment created time in a month

issue openedpwa-builder/PWABuilder

Downloaded zip does not contain iOS project

Describe the bug The iOS download only contains JavaScript files and no iOS project.

To Reproduce Steps to reproduce the behavior:

  1. Go to https://www.pwabuilder.com/
  2. Enter your PWA url ( a known, good one is https://app.ft.com/index_page/home )
  3. Click "Build My PWA"
  4. Click Download button in the iOS section.

Expected behavior I expected an Xcode project.

Screenshots Screenshot 2020-02-13 at 00 47 05

Additional info (please complete the following information):

  • OS: Macos
  • Browser Chrome
  • Browser Version 80

Additional context I tried the same on Firefox and got the same result. (for some URLs, it downloads Manifest.json with the contents of a zip file 🤔 )

created time in 2 months

issue commentsveltejs/sapper

/build/ is dependent on project dir

This might help your cause:

// rollup.config.js
-		external: Object.keys(pkg.dependencies).concat(
+		external: [].concat(
			require('module').builtinModules || Object.keys(process.binding('natives'))
		),
KristerV

comment created time in 2 months

issue commentbeyonk-adventures/now-sapper-demo

SSR for /blog doesn't work on Zeit Now v2

The workaround isn't needed anymore 🎉 Fix has been released in now-sapper v0.39.0! Thanks @fpaboim

tomsoderlund

comment created time in 2 months

issue commentthgh/now-sapper

fetch does not work with local urls on Now

Fix has been released in v0.39.0! Thanks @fpaboim

uunomee

comment created time in 2 months

issue commentthgh/now-sapper

PORT Set to 0 breaks SSR in preload

Released in v0.39.0!

fpaboim

comment created time in 2 months

push eventthgh/now-sapper

Thomas Ghysels

commit sha 9fe8017f0c555d256a40225e352acbe75bf110f8

v0.39.0

view details

push time in 2 months

pull request commentthgh/now-sapper

change port from 0 to 3000

Awesome!

fpaboim

comment created time in 2 months

push eventthgh/now-sapper

Francisco Aboim

commit sha d5e3bee8a9bab68960e1b5c04d8c5602f27f46d5

change port from 0 to 3000

view details

Thomas Ghysels

commit sha 7a8e53aa84d52efc65329bfd9ca374c314a96b29

Merge pull request #21 from fpaboim/port_fix change port from 0 to 3000

view details

push time in 2 months

PR merged thgh/now-sapper

change port from 0 to 3000

Fixes: https://github.com/thgh/now-sapper/issues/20

+45 -1

0 comment

2 changed files

fpaboim

pr closed time in 2 months

issue closedthgh/now-sapper

PORT Set to 0 breaks SSR in preload

Any fetching on the preload function, e.g. as in the blog page, flashes a 500 error when loading. This can be observed with the template project going to the blog page and bringing up the network pane to inspect requests.

closed time in 2 months

fpaboim

issue commentbeyonk-adventures/now-sapper-demo

SSR for /blog doesn't work on Zeit Now v2

Probably related: https://github.com/thgh/now-sapper#using-fetch-serverside

tomsoderlund

comment created time in 2 months

issue commentthgh/rollup-plugin-scss

Consider to use "sass" instead of "node-sass"

PR welcome! I would then prefer to still use node-sass because it's faster. So having both as peerdependencies and allowing developers to choose which one? This would be a major version bump.

dkorobeinikov

comment created time in 2 months

issue commentthgh/rollup-plugin-serve

problem while serving audio/video files

Do you mind reviewing #42?

You could also consider using https://www.npmjs.com/package/rollup-plugin-serve-range

htshah

comment created time in 2 months

Pull request review commentthgh/rollup-plugin-livereload

Only keep 1 server instance running

 export default function livereload (options = { watch: '' }) {     options.watch = options.watch || ''   } -  let enabled = options.verbose === false+  const verbose = options.verbose !== false   const port = options.port || 35729-  const snippetSrc = options.clientUrl ? JSON.stringify(options.clientUrl) : `'//' + (window.location.host || 'localhost').split(':')[0] + ':${port}/livereload.js?snipver=1'`-  const server = createServer(options)+  const snippetSrc = options.clientUrl+    ? JSON.stringify(options.clientUrl)+    : `'//' + (window.location.host || 'localhost').split(':')[0] + ':${port}/livereload.js?snipver=1'` -  // Start watching-  if (Array.isArray(options.watch)) {-    server.watch(options.watch.map(w => resolve(process.cwd(), w)))-  } else {-    server.watch(resolve(process.cwd(), options.watch))+  if (state === 0) {+    start()+  } else if (state === 1) {+    // Starting, just ignore

I thought that by tracking the state of the server, it's easier to avoid multiple servers trying to bind at the same time. Like you say, what if the server takes more time to bind? => multiple servers will try to get the same port. This code makes that impossible.

In the ideal case (if state=1) it should wait until the previous server is started, then stop it and then start a new one with the latest config. But that seems like overengineering.

thgh

comment created time in 2 months

issue commentthgh/now-sapper

PORT Set to 0 breaks SSR in preload

So this would basically fix #8? Will test soon!

fpaboim

comment created time in 2 months

push eventthgh/util

ThomasAndrewMacLean

commit sha ad4f06040760afe0f73edfa127c1d0fce9cc9d55

add function to copy text to clipboard

view details

Thomas Ghysels

commit sha 445e102da408236d93fbec9531bb845fa23845a4

Add support for Airtable mock server

view details

Thomas Ghysels

commit sha 5541ec26a4d4d9d09b2bbd7591546f11ed1c1043

Throw proper Airtable errors

view details

Thomas Ghysels

commit sha d76a7867c024eb5bf528f6d200820559a4d45b77

Merge remote-tracking branch 'gitlab/feature/copyToClipboard'

view details

push time in 2 months

pull request commentthgh/rollup-plugin-livereload

Only keep 1 server instance running

I'm on macos and it seems to work and didn't test anywhere else.

So if I understand correctly, there is two options:

  1. remove the listener entirely and expect the process will close automatically but possibly irritating the user
  2. keep the listener + process.exit and be sure that the process exits but possibly interrupting the cleanup of something else

What would you choose? (I think most people would prefer 2)

PS: just an idea, how about setting a timeout for 1 second and then process.exit?

thgh

comment created time in 2 months

Pull request review commentthgh/rollup-plugin-livereload

close previous server on Rollup reload

 export default function livereload (options = { watch: '' }) {     server.watch(resolve(process.cwd(), options.watch))   } -  closeServerOnTermination(server)+  // hooking on SIGINT/SIGTERM might cause more harm than good, since only one+  // plugin / lib can do that, we might cause process.exit before actual cleanup+  // is all completed -- disabling by default behind an option for now...

This PR and 34 change the behaviour so I would make it v2 with or without termination signals.

rixo

comment created time in 2 months

Pull request review commentthgh/rollup-plugin-livereload

close previous server on Rollup reload

 function green (text) {  function closeServerOnTermination (server) {

As server is now in the root scope, it's not needed to pass the server instance here.

rixo

comment created time in 2 months

Pull request review commentthgh/rollup-plugin-livereload

close previous server on Rollup reload

 export default function livereload (options = { watch: '' }) {     options.watch = options.watch || ''   } +  // release previous server instance if rollup is reloading configuration in watch mode+  if (server) {+    server.close()+    server = null

This line is unneeded as server is reassigned on line 31.

rixo

comment created time in 2 months

PR opened thgh/rollup-plugin-livereload

Only keep 1 server instance running

Alternative approach to #33

  • Move server instance to top scope
  • Remove process.exit() as all server instances will be properly closed
  • Use prettier

Resolve #30 Resolve #31 Resolve #32 Close #33

+50 -25

0 comment

3 changed files

pr created time in 2 months

create barnchthgh/rollup-plugin-livereload

branch : fix-restart

created branch time in 2 months

issue openedPikadudeNo1/svelte-writable-derived

Nested property shorthand syntax

Today I came across this usecase:

<input type="checkbox" bind:value={$items} />

<script>
const existingStore = writable({ items: [] })
const items = writableDerived(mainstore, 'items') // I wish this syntax was supported
</script>

What do you think about supporting this syntax?

created time in 2 months

push eventthgh/now-sapper

Thomas Ghysels

commit sha 35650c3675bc2fea39f7a4d2e75ab6d060ebaef4

Reorder README.md

view details

Thomas Ghysels

commit sha fcb0a43ba482cbdd9633faa1a44356e8cc0b4b1b

Prettier

view details

push time in 3 months

PR merged thgh/now-sapper

Improve README.md
+76 -37

0 comment

3 changed files

thgh

pr closed time in 3 months

push eventthgh/now-sapper

Thomas Ghysels

commit sha d82d96b8743692ed31a9305ef513dd51538914c7

Reorder README.md

view details

Thomas Ghysels

commit sha 38971540ae8bbaa9c23ad9b819c835ad86f5ef40

Prettier

view details

push time in 3 months

issue closedthgh/rollup-plugin-serve

import the serve but not use will also hold the rollup process

I have used rollup-plugin-serve in my devConf and it works well for dev env. But when i run rollup -c rollup.config.js --environment BUILD:prod, rollup actually uses the prodConf and it still hold on after creating the bundle.

This is my rollup.config.js:

// rollup.config.js
import devConf from './build/config.dev';
import prodConf from './build/config.prod';

export default () => {
    if (process.env.BUILD === 'dev') {
        return [prodConf, devConf];
    }
    return prodConf;
}

And the process is holding:

➜  san-color git:(master) ✗ npm run build

> san-color@1.0.0 build /Users/helianthuswhite/Documents/workspace/san-color
> rollup -c rollup.config.js --environment BUILD:prod


src/index.js → dist/san-color.js...
created dist/san-color.js in 2.3s

closed time in 3 months

helianthuswhite

issue commentthgh/rollup-plugin-serve

Is this safe to use with multiple bundles

I'm not aware of a way to detect multiple serve() vs a reload due to rollup watch. So the current behaviour is to close the previous and start a new server everytime serve() is called.

What behaviour would you expect?

CrashyBang

comment created time in 3 months

push eventthgh/now-sapper

Thomas Ghysels

commit sha d82d96b8743692ed31a9305ef513dd51538914c7

Reorder README.md

view details

push time in 3 months

PR opened thgh/now-sapper

Improve README.md
+76 -37

0 comment

3 changed files

pr created time in 3 months

create barnchthgh/now-sapper

branch : readme

created branch time in 3 months

MemberEvent

issue commentthgh/now-sapper

Using "nodejs10.x" as runtime in config causes 502 BAD_GATEWAY error

Thanks @ajbouh and @antony, this has been released in v0.38.0

In the next weeks I will be working on a sapper project that's hosted on Now, so looking forward to enjoy this fix :-)

funkybunky

comment created time in 3 months

issue closedthgh/now-sapper

Using "nodejs10.x" as runtime in config causes 502 BAD_GATEWAY error

In the readme the following is stated: "You can change the AWS lambda runtime from the default node 8 Example now.json"

{
  "version": 2,
  "builds": [
    {
      "src": "package.json",
      "use": "now-sapper",
      "config": {
        "runtime": "nodejs10.x"
      }
    }
  ]
}

But when I add the nodejs 10.x runtime, deploy with now and access the site online, I get an "502: BAD_GATEWAY" error with "Code: NO_STATUS_CODE_FROM_FUNCTION"

I found out that in the demo repo here: https://github.com/beyonk-adventures/now-sapper-demo there is no runtime config added. After removing it, everything worked.

Just stating this in case anybody else runs into this and to maybe update the docs.

closed time in 3 months

funkybunky

push eventthgh/now-sapper

Thomas Ghysels

commit sha f332818c1d719a6183fe405a8a43996f3a8af57f

v0.38.0

view details

push time in 3 months

push eventthgh/now-sapper

Adam Bouhenguel

commit sha f76e0b98b1acc800d0b5da36c1663b125fac59ee

Try using __dirname

view details

Thomas Ghysels

commit sha e70884dbab6cde16a498b6bf247212925f526cd6

Merge pull request #18 from ajbouh/master Enable deployment on 10.x and 12.x engines

view details

push time in 3 months

PR merged thgh/now-sapper

Enable deployment on 10.x and 12.x engines

Amazon decided to do its upgrade and break everything that existed previously, and this appears to be the fix. I'm not going to lie. I have no idea why it works.

+5 -6

1 comment

3 changed files

antony

pr closed time in 3 months

pull request commentthgh/now-sapper

Enable deployment on 10.x and 12.x engines

Sure thing! Resolves #11

antony

comment created time in 3 months

fork thgh/keyv-mongo

MongoDB storage adapter for Keyv

fork in 3 months

issue commentlukechilds/keyv-mongo

Support mongodb gridfs

Hi @adityapatadia thanks for your improvements, do you consider making a pull request now?

You can also clarify how to use the adapter in your readme:

// How to use this adapter
import Keyv from 'keyv'
import store from 'keyv-mongo-gridfs'

const keyv = new Keyv(connectionString, { store })
adityapatadia

comment created time in 3 months

push eventthgh/util

Thomas Ghysels

commit sha 63c56377d1e9954572fc677b149cba8e9b2f9c02

v1.14.0

view details

push time in 3 months

push eventthgh/util

Thomas Ghysels

commit sha f4d72e4e120479a48261b345aefce0871151e8d6

Typescriptify memo and random

view details

push time in 3 months

push eventthgh/ionic-mollie

dependabot[bot]

commit sha 642981728282efdea9ba65a46434e56b7f888727

Bump lodash from 4.17.11 to 4.17.15 in /functions Bumps [lodash](https://github.com/lodash/lodash) from 4.17.11 to 4.17.15. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](https://github.com/lodash/lodash/compare/4.17.11...4.17.15) Signed-off-by: dependabot[bot] <support@github.com>

view details

push time in 3 months

PR merged thgh/ionic-mollie

Bump lodash from 4.17.11 to 4.17.15 in /functions dependencies

Bumps lodash from 4.17.11 to 4.17.15. <details> <summary>Commits</summary>

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


<details> <summary>Dependabot commands and options</summary> <br />

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot ignore this [patch|minor|major] version will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

You can disable automated security fix PRs for this repo from the Security Alerts page.

</details>

+6 -7

0 comment

1 changed file

dependabot[bot]

pr closed time in 3 months

push eventthgh/ionic-mollie

dependabot[bot]

commit sha fbc3af29391601d32e8ea4c1590736cb61231147

Bump handlebars from 4.1.2 to 4.5.3 Bumps [handlebars](https://github.com/wycats/handlebars.js) from 4.1.2 to 4.5.3. - [Release notes](https://github.com/wycats/handlebars.js/releases) - [Changelog](https://github.com/wycats/handlebars.js/blob/master/release-notes.md) - [Commits](https://github.com/wycats/handlebars.js/compare/v4.1.2...v4.5.3) Signed-off-by: dependabot[bot] <support@github.com>

view details

push time in 3 months

PR merged thgh/ionic-mollie

Bump handlebars from 4.1.2 to 4.5.3 dependencies

Bumps handlebars from 4.1.2 to 4.5.3. <details> <summary>Changelog</summary>

Sourced from handlebars's changelog.

v4.5.3 - November 18th, 2019

Bugfixes:

  • fix: add "no-prototype-builtins" eslint-rule and fix all occurences - f7f05d7
  • fix: add more properties required to be enumerable - 1988878

Chores / Build:

  • fix: use !== 0 instead of != 0 - c02b05f
  • add chai and dirty-chai and sinon, for cleaner test-assertions and spies, deprecate old assertion-methods - 93e284e, 886ba86, 0817dad, 93516a0

Security:

  • The properties __proto__, __defineGetter__, __defineSetter__ and __lookupGetter__ have been added to the list of "properties that must be enumerable". If a property by that name is found and not enumerable on its parent, it will silently evaluate to undefined. This is done in both the compiled template and the "lookup"-helper. This will prevent new Remote-Code-Execution exploits that have been published recently.

Compatibility notes:

  • Due to the security-fixes. The semantics of the templates using __proto__, __defineGetter__, __defineSetter__ and __lookupGetter__ in the respect that those expression now return undefined rather than their actual value from the proto.
  • The semantics have not changed in cases where the properties are enumerable, as in:
{
  __proto__: 'some string'
}
  • The change may be breaking in that respect, but we still only increase the patch-version, because the incompatible use-cases are not intended, undocumented and far less important than fixing Remote-Code-Execution exploits on existing systems.

Commits

v4.5.2 - November 13th, 2019

Bugfixes

  • fix: use String(field) in lookup when checking for "constructor" - d541378
  • test: add fluent API for testing Handlebars - c2ac79c

Compatibility notes:

  • no incompatibility are to be expected </tr></table> ... (truncated) </details> <details> <summary>Commits</summary>
  • c819c8b v4.5.3
  • 827c9d0 Update release notes
  • f7f05d7 fix: add "no-prototype-builtins" eslint-rule and fix all occurences
  • 1988878 fix: add more properties required to be enumerable
  • 886ba86 test/chore: add chai/expect and sinon to "runtime"-environment
  • 0817dad test: add sinon as global variable to eslint in the specs
  • 93516a0 test: add sinon.js for spies, deprecate current assertions
  • 93e284e chore: add chai and dirty-chai for better test assertions
  • c02b05f fix: use !== 0 instead of != 0
  • 8de121d v4.5.2
  • Additional commits viewable in compare view </details> <br />

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


<details> <summary>Dependabot commands and options</summary> <br />

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot ignore this [patch|minor|major] version will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

You can disable automated security fix PRs for this repo from the Security Alerts page.

</details>

+66 -22

0 comment

1 changed file

dependabot[bot]

pr closed time in 3 months

push eventthgh/util

Thomas Ghysels

commit sha 9ed6348d5675e2d51474a80a346c3e3c5c8312ad

Don't send content-type with GET requests

view details

Thomas Ghysels

commit sha b12e567ad293f6d63697fd900d3b9b7dbda63bf0

v1.13.0

view details

push time in 3 months

push eventthgh/util

Thomas Ghysels

commit sha ed972cec04a17c8c21c612c60fa51e4fe960b073

Typescriptify airtable, airtable-env, fetch, url

view details

Thomas Ghysels

commit sha a6fae55ca1e6da3890acf718d3ef4330ed96f258

v1.11.0

view details

Thomas Ghysels

commit sha d269b55ec0d654f7bbfa86756d7e19a8eae6356f

v1.12.0

view details

push time in 3 months

release thgh/rollup-plugin-scss

v2.1.0

released time in 3 months

release thgh/rollup-plugin-scss

v2.0.0

released time in 3 months

created tagthgh/rollup-plugin-scss

tagv2.0.0

Rollup and compile multiple .scss, .sass and .css imports

created time in 3 months

more