Using base_path and directory variables in twig template
You can expose the base_path variable to all you templates by implementing hook_preprocess() in your theme .theme file.

e.g. 

/**
 * Implements hook_preprocess().
 */
function mytheme_preprocess(array &amp;$variables, $hook) {
  $variables['base_path'] = base_path();
}


where mytheme is the machine name of your theme.

You can use {{ active_theme_path() }} to get the path to the active theme.