{"size": 1205, "ext": "js", "max_stars_repo_path": "packages/core/dist/cjs/src/hooks/useEthers.js", "max_stars_repo_name": "qapquiz/useDApp", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "packages/core/dist/cjs/src/hooks/useEthers.js", "max_issues_repo_name": "qapquiz/useDApp", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "packages/core/dist/cjs/src/hooks/useEthers.js", "max_forks_repo_name": "qapquiz/useDApp", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 41.5517241379, "max_line_length": 106, "alphanum_fraction": 0.6622406639}
"use strict";
var __assign = (this && this.__assign) || function () {
    __assign = Object.assign || function(t) {
        for (var s, i = 1, n = arguments.length; i < n; i++) {
            s = arguments[i];
            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
                t[p] = s[p];
        }
        return t;
    };
    return __assign.apply(this, arguments);
};
exports.__esModule = true;
exports.useEthers = void 0;
var core_1 = require("@web3-react/core");
var react_1 = require("react");
var context_1 = require("../providers/config/context");
var injected_connector_1 = require("@web3-react/injected-connector");
function useEthers() {
    var result = core_1.useWeb3React();
    var supportedChains = context_1.useConfig().supportedChains;
    var activateBrowserWallet = react_1.useMemo(function () {
        var injected = new injected_connector_1.InjectedConnector({ supportedChainIds: supportedChains });
        return function () { return result.activate(injected); };
    }, [supportedChains]);
    return __assign(__assign({}, result), { activateBrowserWallet: activateBrowserWallet });
}
exports.useEthers = useEthers;
//# sourceMappingURL=useEthers.js.map