@@ -147,7 +147,7 @@
Loading
147 147
  }
148 148
149 149
  loadBuiltinPlugins(options: Options) {
150 -
    const plugins = builtinPlugins.reduce((acc: Plugin[], plugin) => {
150 +
    const plugins = builtinPlugins(options).reduce((acc: Plugin[], plugin) => {
151 151
      acc.push(plugin.init({}, options));
152 152
      return acc;
153 153
    }, []);

@@ -1,17 +1,24 @@
Loading
1 1
import errorScreen from '@remax/plugin-error-screen';
2 2
import devtools from '@remax/plugin-devtools';
3 -
import { Plugin } from '@remax/types';
3 +
import { Options, Platform, Plugin } from '@remax/types';
4 4
5 -
export const builtinPlugins: Array<{
5 +
export const builtinPlugins = (
6 +
  options: Options
7 +
): Array<{
6 8
  optionKey: string;
7 9
  init: (...args: any[]) => Plugin;
8 -
}> = [
9 -
  {
10 -
    optionKey: 'errorScreen',
11 -
    init: errorScreen,
12 -
  },
13 -
  {
14 -
    optionKey: 'devtools',
15 -
    init: devtools,
16 -
  },
17 -
];
10 +
}> => {
11 +
  const plugins = [
12 +
    {
13 +
      optionKey: 'errorScreen',
14 +
      init: errorScreen,
15 +
    },
16 +
  ];
17 +
  if (options.target !== Platform.web) {
18 +
    plugins.push({
19 +
      optionKey: 'devtools',
20 +
      init: devtools,
21 +
    });
22 +
  }
23 +
  return plugins;
24 +
};
Files Coverage
packages 90.76%
Project Totals (363 files) 90.76%
6913.1
TRAVIS_OS_NAME=linux
stable=

No yaml found.

Create your codecov.yml to customize your Codecov experience

Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading