-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5911 from storybooks/4995-custom-presets
Remove custom presets warning
- Loading branch information
Showing
1 changed file
with
1 addition
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,7 @@ | ||
import path from 'path'; | ||
import { logger } from '@storybook/node-logger'; | ||
import serverRequire from '../utils/server-require'; | ||
|
||
export default function loadCustomPresets({ configDir }) { | ||
const presets = serverRequire(path.resolve(configDir, 'presets')); | ||
|
||
if (presets) { | ||
logger.warn( | ||
'"Custom presets" is an experimental and undocumented feature that will be changed or deprecated soon. Use it on your own risk.' | ||
); | ||
|
||
return presets; | ||
} | ||
|
||
return []; | ||
return presets || []; | ||
} |