jodit
Version:
Jodit is an awesome and useful wysiwyg editor with filebrowser
20 lines (19 loc) • 575 B
JavaScript
/*!
* Jodit Editor (https://xdsoft.net/jodit/)
* Released under MIT see LICENSE.txt in the project root for license information.
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
*/
/**
* @module helpers/checker
*/
import { isNumeric } from "./is-numeric.js";
import { isString } from "./is-string.js";
/**
* Check value is Int
*/
export function isInt(value) {
if (isString(value) && isNumeric(value)) {
value = parseFloat(value);
}
return typeof value === 'number' && Number.isFinite(value) && !(value % 1);
}