Hey tessus,
Thanks for the feedback. That would be amazing! But I do not have any expertise in javascript and do not have much band width to take on learning the skill - does anyone in the community have the skill?
Just wondering, why would it have to be javascript?
In regards to point 2, how would I do this? I apologize - just not very familiar with the architecture of Joplin.
I feel this would be a great feature to add.
Thanks!
EDIT:
I attempted converting my Python script to JavaScript - can you tell me if it works as a JS function? It should function exactly as the Python one did.
I used Transcrypt to convert my Python to JS - I am not JS programmer but it looks rather messy.
'use strict';
var sys = {};
import {
AssertionError,
AttributeError,
BaseException,
DeprecationWarning,
Exception,
IndexError,
IterableError,
KeyError,
NotImplementedError,
RuntimeWarning,
StopIteration,
UserWarning,
ValueError,
Warning,
__JsIterator__,
__PyIterator__,
__Terminal__,
__add__,
__and__,
__call__,
__class__,
__envir__,
__eq__,
__floordiv__,
__ge__,
__get__,
__getcm__,
__getitem__,
__getslice__,
__getsm__,
__gt__,
__i__,
__iadd__,
__iand__,
__idiv__,
__ijsmod__,
__ilshift__,
__imatmul__,
__imod__,
__imul__,
__in__,
__init__,
__ior__,
__ipow__,
__irshift__,
__isub__,
__ixor__,
__jsUsePyNext__,
__jsmod__,
__k__,
__kwargtrans__,
__le__,
__lshift__,
__lt__,
__matmul__,
__mergefields__,
__mergekwargtrans__,
__mod__,
__mul__,
__ne__,
__neg__,
__nest__,
__or__,
__pow__,
__pragma__,
__proxy__,
__pyUseJsNext__,
__rshift__,
__setitem__,
__setproperty__,
__setslice__,
__sort__,
__specialattrib__,
__sub__,
__super__,
__t__,
__terminal__,
__truediv__,
__withblock__,
__xor__,
abs,
all,
any,
assert,
bool,
bytearray,
bytes,
callable,
chr,
copy,
deepcopy,
delattr,
dict,
dir,
divmod,
enumerate,
filter,
float,
getattr,
hasattr,
input,
int,
isinstance,
issubclass,
len,
list,
map,
max,
min,
object,
ord,
pow,
print,
property,
py_TypeError,
py_iter,
py_metatype,
py_next,
py_reversed,
py_typeof,
range,
repr,
round,
set,
setattr,
sorted,
str,
sum,
tuple,
zip
} from "./org.transcrypt.__runtime__.js";
import * as __module_sys__ from "./sys.js";
__nest__(sys, "", __module_sys__);
var __name__ = "__main__";
export var filename = sys.argv[1];
export var out_file = sys.argv[1].__getslice__(0, -3, 1) + "md";
var f = open(filename);
try {
f.__enter__();
var of = open(out_file,
"w");
try {
of .__enter__();
var i = 0;
for (var line of f)
if (i == 0) {
var line = line.strip("\n");
var line = line.py_split("|");
var columns = len(line); of .write("|".join(function() {
var __accu0__ = [];
for (var x of line) __accu0__.append(str(x));
return __accu0__
}()) + "\n"); of .write("|:---: " * columns + "|\n");
var i = 1
} else {
var line = line.strip("\n");
var line = line.py_split("|"); of .write("|".join(function() {
var __accu0__ = [];
for (var x of line) __accu0__.append(str(x));
return __accu0__
}()) + "\n")
} of . __exit__()
} catch (__except0__) {
if (! of .__exit__(__except0__.name,
__except0__, __except0__.stack)) throw __except0__;
}
f.__exit__()
} catch (__except0__) {
if (!f.__exit__(__except0__.name, __except0__, __except0__.stack)) throw __except0__;
};
//# sourceMappingURL=test.map