MCPcopy Create free account
hub / github.com/BYVoid/OpenCC / getConfigPath

Function getConfigPath

node/opencc.js:118–125  ·  view source on GitHub ↗
(config)

Source from the content-addressed store, hash-verified

116};
117
118const getConfigPath = function (config) {
119 let configPath = config;
120 if (!isAbsolutePath(config)) {
121 // Resolve relative path
122 configPath = path.join(assetsPath, config);
123 }
124 return configPath;
125};
126
127/**
128 * Recursively resolve all dict "file" paths in a config object to absolute

Callers 1

opencc.jsFile · 0.85

Calls 2

isAbsolutePathFunction · 0.85
joinMethod · 0.45

Tested by

no test coverage detected