Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

switch the declare/import-var function to def in state.api #171

Merged
merged 2 commits into from
Dec 11, 2023

Conversation

dimmyjr-nu
Copy link
Contributor

The switch successfully resolved the issue related to the recognition function in IntelliJ and other IDEs. We recently encountered a problem while attempting to integrate "state-flow" into ClojureDocs, where the functions in the namespace were not being displayed as expected.

About the problem

  • The declare was a workaround used to avoid IntelliJ not showing an error for not finding the function or an object from the namespace.
  • About the import-vars the problem is when copying the function from other namespaces together with meta. For Intellij is a problem because is dynamic (apparently Intellij uses static code). For clojuredocs is because the function meta :ns is extracted too, given the idea that even if the function is imported into the state.api namespace, the function is from the source namespace

Behavior in IntelliJ

  • as Is
    image
  • to be

We have the docstring and the parameters
image

Behavior in ClojureDocs

  • as is
    image
  • to be
    image

@dimmyjr-nu dimmyjr-nu force-pushed the redeclare-function-in-api branch from 62f66f3 to c78dfb0 Compare November 23, 2023 20:03
@dimmyjr-nu dimmyjr-nu marked this pull request as ready for review December 7, 2023 13:57
@dimmyjr-nu dimmyjr-nu merged commit e86f513 into master Dec 11, 2023
3 of 4 checks passed
@dimmyjr-nu dimmyjr-nu deleted the redeclare-function-in-api branch December 11, 2023 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants