const toolbox = require('sw-toolbox');

// Try network but fallback to cache
toolbox.router.default = toolbox.networkFirst;

// Data should query the network first
toolbox.router.any('/api/*', toolbox.networkOnly);

// Data should query the network first
toolbox.router.any('/auth/*', toolbox.networkOnly);

import {router} from 'sw-toolbox';

// Try network but fallback to cache
router.default = toolbox.networkFirst;

// Data should query the network first
router.any('/api/*', toolbox.networkOnly);

// Data should query the network first
router.any('/auth/*', toolbox.networkOnly);

Use import rather than require
Use import rather than require
