UNPKG

node-red-contrib-chatbot

Version:

REDBot a Chat bot for a full featured chat bot for Telegram, Facebook Messenger and Slack. Almost no coding skills required

16 lines (13 loc) 351 B
import { useContext } from 'react'; import AppContext from '../common/app-context'; const useSettings = () => { const { state } = useContext(AppContext); if (state != null) { return state.settings; } else if (window.bootstrap?.settings) { return window.bootstrap?.settings; } else { return {}; } }; export default useSettings;