Wait for codemirror value on page